Adapative Huffman Coding Algoritm homework