Gray code representation of (27)₁₀ is ____

2021

Gray code representation of (27)₁₀ is ____

  1. A.

    11011

  2. B.

    11100

  3. C.

    10110

  4. D.

    11010

Attempted by 93 students.

Show answer & explanation

Correct answer: C

First, convert (27)₁₀ to binary:
(27)₁₀ = 110112

Now we convert binary to Gray code using the rule:

  1. The first Gray bit is the same as the first binary bit.

  2. Each subsequent Gray bit is obtained by XORing adjacent binary bits.
    B = 11011
    G1 = 1
    G2 = 1 ⊕ 1 = 0
    G3 = 1 ⊕ 0 = 1
    G4 = 0 ⊕ 1 = 1
    G5 = 1 ⊕ 1 = 0

So, Binary (11011) converts to Gray (10110), so the answer is correct.

Explore the full course: Up Lt Grade Assistant Teacher 2025