Compression of random binary data

Thomas Jollans tjol at tjol.eu
Mon Oct 23 05:54:34 EDT 2017


On 2017-10-23 11:32, danceswithnumbers at gmail.com wrote:
> According to this website. This is an uncompressable stream.
> 
> https://en.m.wikipedia.org/wiki/Incompressible_string
> 
> 1234999988884321

No, it's not. According to that article, that string is incompressible
by a particular algorithm. I can see no more general claims.

> 
> It only takes seven 8 bit bytes to represent this
> 

You amaze me.

>>> bin(1234999988884321)
'0b100011000110011100111010111101000101001001101100001'
>>> len(bin(1234999988884321)[2:])
51
>>> 7 * 8
56





More information about the Python-list mailing list