I'm pretty confused so I hope I don't mix up the different terms here.
The two's complement representation of decimal
The two's complement of
- I imagine that complementing a number is equivalent to flipping bits in binary
The nine's complement of
- This is what confuses me. Are two's complement and nine's complement similar (except for the base change obviously)?
- If they are, then I'd expect the nine's complement of
8is the biggest digit in radix
9and therefore the complement operation would assign the highest digit (
8) to the lowest value input (
0) [I imagine a folding from the center]
Obviously this is totally wrong but I'm not sure which part I've misunderstood.