4 ms·
You could just store using offsets instead. You don't have to do sign bit. 2 bit example: 00 => -1 01 => 0 10 => 1 11 => 2 or: 2 bit example: 00 => -2 01 =>
by julian-klode 11y ago
You could just store using offsets instead. You don't have to do sign bit.
2 bit example:
00 => -1
01 => 0
10 => 1
11 => 2
or:
2 bit example:
00 => -2
01 => -1
10 => 0
11 => 1
This even wrapsaround naturally.