If negative numbers are encoded as 2's complement, addition and subtraction works much more easily. You can add 2's-complement-encoded numbers with the usually binary addition method, whereas the signed-magnitude method of encoding negative numbers (for which the leftmost bit is assigned to carry the minus sign information) is not compatible with that.
Take the example from class:
The 2's complement version of is 00111111, and of
is
11000001. Now add these (by the method in the question above, i.e., in each place
``carry'' a resulting 1 to the next-most-significant bit, and continue right to left).
This yields 00000000, which is what you expect from adding
and
.
Now suppose you try the same with signed-magnitude-encoded numbers.
in signed-magnitude binary is
, which by binary
addition yields
, which is not zero. So adding these requires some
tricky manipulation.
(We'll see how to implement the carry-the-overflow-bit method of binary addition in digital electronics a couple of lectures from now.)