Quote:
Originally posted by Skabana159
Third, that word is an unsigned integer. It is in a format that I do not completely understand called the two's complement. Someone else will have to tell you what this means because I really have no idea. It will be a positive integer, but there is some way to tell if it is a negative value.
|
In two's complement, the first bit of a number represents the opposite of what it normally would. So, in a two's complement byte, 10000000 would represent -128 instead of +128. All of the other bits count as positive values.
Another example:
10000001 in two's complement is 1 + -128 = -127, while as an unsigned integer it would be 1 + 128 = 129.