Huffman code for the letters a,b,c,d,e - 0,10,110,1110,1111

Q.  Algorithms: What will be the Huffman code for the letters a,b,c,d,e?
- Published on 24 Jun 15

a. 0,10,110,1110,1111
b. 10,011,11,001,010
c. 10,01,0001,100,1010
d. 100,110,001,000,010

ANSWER: 0,10,110,1110,1111
 
The probability are ½,1/4, 1/8,1/16,,1/32
So, the Huffman code according to the tree is unique.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)