News for hackers. Stuff that matters.
Re:Building a data compression utility in Haskell using Huff... by imurray on Thursday July 04, 2024 @10:52AM (#40875414)
That code in the EDIT is suboptimal. It doesn't saturate the Kraft inequality. You could make every codeword two bits and still encode 4 symbols, so that would be strictly better.
Re:Building a data compression utility in Haskell using Huff... by n4r9 on Thursday July 04, 2024 @10:58AM (#40875467)
Ah of course. Thanks for the insight. About 15 years since I studied this stuff!