Question:

Someone help me convert to binary?

by  |  earlier

0 LIKES UnLike

x = 8

x = 12

x = 1.5

x = 1.25

I can do 8 and 12, but if someone would explain the last two I'd appreciate it!

 Tags:

   Report

3 ANSWERS


  1. Not too hard. Binary fractions work just like decimal fractions, except each place to the right is 1/2 the value of the previous.

    1000 = 8

    0100 = 4

    0010 = 2

    0001 = 1

    0.1000 = 1/2

    0.0100 = 1/4

    0.0010 = 1/8


  2. 256 | 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1

    Think of those as place holders in binary

    2^0, 2^1, 2^2, 2^3...etc.

    Since 8 = 2^3, in binary it is (1000)

    So for x = 12, (1100)

    Treat x = 1.5 as two parts, the integer and the fraction, 1/2

    For integers do it as usual; for fractions, multiply by 2 until

    remainder = 0

    x = 1.5 (1.1) in binary

    x= 1.25 is (1.01) in binary.

  3. Consider the digits to the right of the decimal point in a decimal number like 1.25. The two means 2 times 1/10 (or 10 ^ -1) and the five means 5 times 1/100 (or 10 ^ -2).

    By that logic, in binary the first digit to the right of the point would be 1/2 (or 2 ^ -1), the second 1/4 (or 2 ^ -2), the third 1/8 (or 2 ^ -3), etc.

    So 1.5 in decimal is the same as 1.1 in binary. Likewise, 1.25 in decimal is the same as 1.01 in binary.

Question Stats

Latest activity: earlier.
This question has 3 answers.

BECOME A GUIDE

Share your knowledge and help people by answering questions.
Unanswered Questions