Convert into binary

What is/are the binary representation(s) of the decimal number 113?

  1. 1110011
  2. 1011001
  3. 1110000
  4. 1110001
  5. 0110001

Solution

Let’s convert 113 (decimal) into binary step by step:

Division by 2

What is the correct translation of the decimal number 23 into binary and hexadecimal representations, respectively?

  1. \(10111_2\) and 0x18
  2. \(11101_2\) and 0x17
  3. \(10111_2\) and 0x17
  4. \(10101_2\) and 0x18
  5. \(11101_2\) and 0x18

Solution

Step 1: Decimal → Binary

Step 2: Decimal → Hexadecimal

Let's devide \(23_{10} \) from 16

So 23 = ox17 in hexadecimal

Correct Option: (c) 10111₂ and 0x17

🤔 Why is there 0x?

The 0x at the start is just a prefix that programmers use to show, "Hey, the number after this is in hexadecimal, not decimal."

For example:

  • 23 → decimal
  • 0x17 → hexadecimal (which is still 23 in decimal)
  • 0b10111 → binary (same value, different representation)

It’s not part of the number itself — it’s like a label so humans and computers know the base:

Prefix Meaning Example
0x Hexadecimal (base 16) 0x17 = 23 decimal
0b Binary (base 2) 0b10111 = 23 decimal
none Decimal (base 10) 23 = 23 decimal

Without 0x, a computer or reader might confuse 17 as decimal instead of hex.


What is the binary value of the decimal number 11/64?

  1. 0.010111
  2. 0.001101
  3. 0.001110
  4. 0.001011
  5. 0.000111

Solution

for fractions where the denominator is a power of 2, you can skip decimal conversion entirely and go straight to binary.

Here’s the trick for 11/64:

  1. Recognize the denominator
  2. \(64 = 2^6\)→ so the binary will have 6 places after the point.

  3. Write the numerator in binary
  4. 11 in binary = 1011

  5. Place it over 6 fractional bits
  6. Since denominator is \(2^6\), write numerator in binary with 6 bits after the point:

    $$ \frac{11}{64} = 0.001011_2 $$

    Binary works exactly the same way — except the “base” is 2 instead of 10.

Why it works

In binary,$$\frac{\text{numerator}}{2^n}=0.(\text{numerator in n bits})$$

for example: $$\frac{11}{2^6}= 0.001011_2$$

No decimal math needed.

Why it works: In binary

In decimal, you know this rule: $$\frac{\text{integer}}{10^n} = 0.(\text{integer in n decimal digits})$$

Binary works exactly the same way — except the “base” is 2 instead of 10.

If the denominator is \(2^n\), then:

  • You take the numerator in binary
  • You place the binary point so that n bits come after it

That’s because dividing by \(2^n\) in binary is simply shifting the binary point n places to the left.

Step-by-step logic

  1. Binary place values (after the point) are:
  2. So if your denominator is $$\frac{1}{2},\frac{1}{4},\frac{1}{8},\frac{1}{16},\frac{1}{32}, \frac{1}{64}...$$
  3. Writing the numerator in binary and padding it to n bits means you’re directly representing it in those fractional place values.

Another way of solving the same problem

  1. Let's convert fraction into decimal form
  2. Then, convert fractional part to binary
  3. multiply repeatedly by 2, keeping track of the integer parts:

  4. Combine
  5. Reading the integer parts in order: \(0.001011_2\)


Convert the decimal number 151.75 to binary?

  1. 10000111.11
  2. 11010011.11
  3. 00111100.11
  4. 10010111.11
  5. 10011101.11

Let’s convert 151.75 into binary step-by-step.

Step 1: Convert the integer part (151)

Read from bottom to top:

\(151 = 10010111_2\)

Step 2: Convert the fractional part (0.75)

So \( 0.75 = 0.11_2\)

Step 3: Combine $$151.75_{10}=10010111.11_2$$

✅ Correct answer: (d) 10010111.11


When using the repeated division by 2 method of converting from decimal to binary, one must write the first remainder as the

  1. Most Significant Bit (MSB)
  2. MSB, provided the following sequence of remainders is written in descending order until the final remainder is achieved.
  3. Least Significant Bit (LSB)
  4. LSB, provided the final remainder is used to replace the original LSB, which is then moved to the MSB position.
  5. Sign Bit, provided the following sequence of remainders is written in descending order until the final remainder is achieved.(a) Most Significant Bit (MSB)

Solution

When we use the repeated division by 2 method:

  • We divide the decimal number by 2 repeatedly.
  • The first remainder we get is actually the Least Significant Bit (LSB) of the binary number.
  • The last remainder we get (when the quotient becomes 0) is the Most Significant Bit (MSB).

That’s why we always write the remainders in reverse order from how they are calculated.

Correct answer: (c) Least Significant Bit (LSB)


Which of the following binary numbers is equivalent to the hexadecimal number 7FF5?

  1. 0111111111110111
  2. 0111111111110101
  3. 0111111111111101
  4. 0111111111110100
  5. 0111111111110100

Solution

Step 1: Hex → Binary mapping

F means 15. Each hex digit = 4 binary bits.

Hex: 7 f f 5

  • 7 = 0111
  • F = 1111
  • F = 1111
  • 5 = 0101

Step 2: Combine $$7FF5_{16}=0111 1111 1111 0101_2$$

Correct answer: (b) 0111111111110101

Popular posts from this blog

Evolution of computers and Computers today

Processor Types and Specifications