Comment by kulahan

7 months ago

There probably aren’t any perfectly lossless compression algorithms, I guess? Nothing would ever be all zeroes, so it might not be an edge case accounted for or something? I have no idea, just pulling at strings. Maybe someone smarter can jump in here.

No lossless algorithm can compress all strings; some will end up larger. This is a consequence of the pigeonhole principle.