1.

What is the 2’s complement of this string “01010100”?(a) 10101010(b) 00110100(c) 10101100(d) 10101001This question was posed to me in exam.Origin of the question is Logic and Bit Operations in section The Foundation: Logics and Proofs of Discrete Mathematics

Answer»

The CORRECT option is (c) 10101100

For explanation: In two’s COMPLEMENT negate every bit from left until the FIRST one from right is ENCOUNTERED.



Discussion

No Comment Found

Related InterviewSolutions