2's Complement Subtraction
Two's complement subtraction is the binary addition of the minuend to the 2's complement of the subtrahend (adding a negative number is the same as subtracting a positive one).For example,
| 7 - 12 = (-5) | 0000 0111 | = | +7 | |
| + 1111 0100 | = | -12 | ||
| 1111 1011 | = | -5 |
No comments:
Post a Comment