Huffman implementation, serializator added