Logic circuits

Which bit pattern represents −1 in 4-bit two's complement?

  1. A1111
  2. B1001
  3. C0001
Show answer and explanation

Answer: A. 1111

In two's complement, a negative number is formed by inverting the bits of the positive value and adding 1: +1 (0001) → 1110 → 1111 = −1. Treating the top bit as having weight −8, 1111 = −8 + 4 + 2 + 1 = −1 can be read directly. Four bits cover −8 to +7, and since subtraction becomes addition of a complement, nearly every computer uses it. 1001 is −1 in sign-magnitude form.