two's complement
The way every modern processor stores signed integers - the top bit counts as a large negative amount, and one adder works for both signs.
In n-bit two's complement, bit n-1 has weight -2^(n-1) and the others their usual positive weights, giving the range -2^(n-1) to 2^(n-1)-1; -x is (NOT x) + 1, which equals 2^n - x modulo 2^n.
Examples
In 8 bits, −5 is
11111011(0xFB): invert00000101to11111010, then add 1.
See also