Quote:
Originally Posted by something
A signed 4-bit value would only be able to represent values from 4 to -4. Check out two's complement on wikipedia for more info on binary representations of negative numbers.
|
Actually, 4 bits provides 16 possible combinations of 0 and 1 so it can represent 0 to 15 as an unsigned integer or -8 to +7 as a signed integer.
(unsigned integer in this case being a mathematical term rather than the C type).
Yes, typically computers represent signed integers as two's complement so negative numbers have the high bit set.