As most people here know, by using 4 bits, we are able to count from 0 to 15 (0123456789ABCDEF in hexadecimal). But if we were to only count up to 9, we would still be using 4 bits, and the digits from A through F would be wasted.
However, Wikipedia's QR-Code page states that using only numerical digits from 0 to 9 uses 3⅓ bits per character, which is correct from a statistical stand point. And yet a third of a bit is not a physical object, and sending a number from 0 to 9 uses at least 4 bits to my knowledge.
Is there any way to use the wasted combinations to effectively send a character with fractions of bits?
OK, let me give an example: The two digits "27" must be sent. With normal coding techniques, the bits sent would be 00100111. We could then imagine a system that would replace the digit '2' by the digit 'E' or 'F', depending on the next bit; in this case the next bit is 0, so the '2' is replaced by 'E'. The resulting bit-string would then be 11010111. On the other hand if the digits "28" must be sent, the first bit after the '2' is a 1, so it is replaced by the digit 'F' instead, yielding the string 11111000.
In both case, an economy of 1 bit has been effected, because one nibble was used for two different characters. In other word, three and a half bits are used on each character.
(10 * first_digit) + second_digit
and encode that into 7 bits, representing 0...99, with the codes 100-127 left over for other things. And there's even more savings with 3 digits compressed into 10 bits. \$\endgroup\$