Question discussion

Two 4-bit two's complement numbers, 0111 and 0101, are added. Which of the following statements is correct?

2121Medium DSSSB TGT Computer Science 0 replies 1 views
0

Two 4-bit two's complement numbers, 0111 and 0101, are added. Which of the following statements is correct?

  • AThe sum is 1100 and no overflow occurs
  • BThe sum is 0010 and a carry-out is produced
  • CThe sum is 1100 and overflow occurs, because +12 cannot be represented
  • DThe sum is 1100, which correctly represents +12
Correct answer: C

Explanation

7 + 5 = 12 exceeds the 4-bit range of -8 to +7; the result 1100 is read as -4, and overflow is signalled because two positive numbers gave a negative result.

Discussion 0

Nobody has replied yet. Start the discussion!