CDAP interview question

Huffman encoding (greedy)