4 ms·
Just to be clear -- b/c I got a bit confused reading this -- this example seems to assume "12345" and "71" are base-256 numbers and "256" is base-10.
by bostonpete 6y ago
Just to be clear -- b/c I got a bit confused reading this -- this example seems to assume "12345" and "71" are base-256 numbers and "256" is base-10.
- Zircom 6y agoOnce you compress the number it becomes stored in base-256 due to how the gzip file format works was my understanding
- bostonpete 6y agoSure, the benefit of base-256 is that a 0 maps to a byte with all 0's in the binary representation of the integer -- it's nothing specific to gzip. But on its face, 12345x256^8+71 = 1234500000071 is just wrong and only works once you realize that it's combining integers from different number systems.