Skim §2 for parts you don't remember
In the following questions, let B
be the maximum number (closest to postiive infinity) and S
the minimum (closest to negative infinity) in the number system listed.
Question 1: (see above) In two's compliment,
Question 2: (see above) In unsigned binary,
Question 3: Assume x
and y
are binary numbers. Let u
be the result of adding x
and y
using unsigned arithemtic and s
be the result of adding x
and y
using signed (two's compliment) arithmetic. Assume all values are 64-bits long.
Question 4: Suppose you have a 32-bit unsigned int
value initialized with a hexidecimal constant like 0xa180039b
.
If you change just one hexadecimal digit in the constant, what is the maximum number of bits that could change?