huffman

Pure Haskell implementation of the Huffman encoding algorithm

Latest on Hackage:1.0.1

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

BSD-3-Clause licensed by Maxime Henrion
Maintained by Maxime Henrion

A simple and pure Haskell implementation of the Huffman encoding algorithm.

The huffman function provides the original O(n log n) algorithm implemented with a priority queue. If the input symbols are sorted by probability, the O(n) huffmanSorted function can be used instead.