The 2's-complement representation of the decimal value -15, using the minimum…
2002
The 2's-complement representation of the decimal value -15, using the minimum number of bits, is:
- A.
1111
- B.
11111
- C.
111111
- D.
10001
Attempted by 30 students.
Show answer & explanation
Correct answer: D
In 2's-complement notation, the number of bits must be fixed. The value -15 cannot be represented in 4 bits because the 4-bit range is -8 to +7. Using the minimum possible width, we need 5 bits. Write +15 as 01111, take the 1's complement to get 10000, and add 1. This gives 10001. Hence the 2's-complement representation of -15 using the minimum number of bits is 10001.