Question 2Asked in Bihar STET Paper 2 Computer Science (Class 11-12), 12 Sep 2023, Shift 2

Which of the following is a self-complementing binary code, where adjacent codes differ in only one bit position?

  1. ABCD
  2. BASCII
  3. CGray Code
  4. DEBCDIC
Show answerHide answer

Correct answer: (C) Gray Code

Explanation

Codes in which adjacent values differ in only one bit are Gray codes; this unit-distance property is what the question describes. (Strictly, the classic self-complementing code is Excess-3, but the one-bit-change description fits only Gray code.)

From Bihar STET Paper 2 Computer Science (Class 11-12) PYQ, 12 Sep 2023, Shift 2

This is question 2 of Bihar STET Paper 2 Computer Science (Class 11-12) PYQ, 12 Sep 2023, Shift 2. See all questions of this paper with answers, or attempt the paper as a timed online test to get your score and all-India rank.