About 53 results
Open links in new tab
  1. c++ - Decimal to binary converting - Stack Overflow

    4 For this , In C++ you can use itoa () function .This function convert any Decimal integer to binary, decimal , hexadecimal and octal number.

  2. Converting Decimal to Binary Java - Stack Overflow

    Feb 9, 2013 · I am trying to convert decimal to binary numbers from the user's input using Java. I'm getting errors. package reversedBinary; import java.util.Scanner; public class ReversedBinary { …

  3. repeat - Converting a repeating binary number to decimal (express as a ...

    4 Given a binary number that repeats, for example 0. (0011) or 0.0 (101), how would one go about converting it to decimal? This can be solved (ie the exact rational quantity can be determined) in …

  4. How to convert decimal to binary in JS? - Stack Overflow

    Sep 30, 2014 · Note that this answer doesn't correctly convert negative decimal numbers to binary as represented in memory. If that's important to you see @Gepser Hoil's answer.

  5. converting decimal to signed binary - Stack Overflow

    Jun 7, 2015 · 1 It depends on what your binary representation is -- ones complement, twos complement, sign-magnitude, or something else. The "invert bits and add 1" is correct for twos complement, which …

  6. Converting a number to binary with a fixed length

    42 Say I get a random number between 1 and 127. I change the number to binary and remove the 0b from it with the following code:

  7. Converting integer to binary in Python - Stack Overflow

    format(a, 'b') returns the binary value of a in string format. To convert a binary string back to integer, use int () function.

  8. binary - Converting Decimal to Two's-Complement - Stack Overflow

    Sep 23, 2013 · Instructions: Convert these decimal numbers to 5-bit 2's-complement form, if possible. If not possible, explain why this is so. (16) base 10 According to the online converter: From what I …

  9. Converting decimal with comma to binary - Stack Overflow

    Jun 14, 2022 · I'm trying to convert decimal numbers with commas into binary. I've seen that if you have for example the number 5.2 in decimal you convert it to 101.10, since 5 is 101 and 2 is 10 but I've …

  10. converting a decimal into binary in the most optimal way possible

    Oct 2, 2013 · What is the most optimal way to convert a decimal number into its binary form ,i.e with the best time complexity? Normally to convert a decimal number into binary,we keep on dividing the …