huffman encoding work