Used C++ STL heap instead for Huffman tree building