Compressing and decompressing text files with Huffman algorithm in Java