Current location - Training Enrollment Network - Mathematics courses - Note: the complement representation of the number 0 is unique: the complement of +0 = the complement of+0 = the complement of+0 = 0000000-0 =11165438.
Note: the complement representation of the number 0 is unique: the complement of +0 = the complement of+0 = the complement of+0 = 0000000-0 =11165438.
The original code, complement and complement of positive numbers are all the same. 0 has two original codes and complements, but the complement of 0 is unique.

The original code of negative number is machine word length, and the first digit is1; Anticode is the inversion of other values except that the first bit of the original code is 1, (1 becomes 0, and 0 becomes1); The complement is the complement plus 1.

Assuming that the machine word is 8 bits long, then

The original code of -0 is/kloc -0/000000, and the complement of -0 is 1 1 1, and the complement of-0 is1.

There will be confusion when people feel +0 and -0. Mathematically 1+(- 1)=0, so it should be -0 or +0 in the computer (I can't understand +0 and -0 anyway). Finally, I can only use the complement to calculate the negative number, and the result will be correct.