[Haskell-cafe] Huffman Codes in Haskell

Andrew Coppin andrewcoppin at btinternet.com
Tue Jun 22 16:18:30 EDT 2010


Don Stewart wrote:
>     http://hackage.haskell.org/package/huffman
>
>     A simple and pure Haskell implementation of the Huffman encoding algorithm.
>   

What the...?

Oh, I see. It uses another package to handle the tricky sorting and 
searching stuff. Well, yeah, that would make the code a bit shorter... ;-)

Even so, it's not nearly as elegant to behold as, say, the quicksort 
algorithm, despite being of roughly similar complexity. Still, it's 
shorter than what I had.



More information about the Haskell-Cafe mailing list