go to previous page   go to home page   go to next page

Answer:

1111111110101011      representation of -85 in sixteen-bit two's complement

Sign Extension

Recall: to increase the number of bits in a representation of an integer in two's complement, add copies of the leftmost bit (the sign bit) to the left until you have the desired number of bits. This is called sign extension. (See chapter 13.)

For example, here is an eight-bit two's complement representation of some integer:

1001 0110

and here is the 16-bit two's complement representation of the same integer:

1111 1111 1001 0110

(In the above, the bits have been grouped into 4-bit nibbles. Of course, the spaces are not significant.)


QUESTION 12:

How is 32 represented in binary?


go to previous page   go to home page   go to next page