Jump to content

Huffman coding: Difference between revisions

m
changed freq. so freq order != letter order
(Gave non-sorted example for test runs.)
m (changed freq. so freq order != letter order)
Line 27:
 
Write a program which reads in symbols and frequencies in pairs separated by whitespace and generates Huffman codes for each symbol. Test your program with the following line of letter frequencies, as input:
<pre>"B 25 C 122.5 D 12.5 A 505 \n"</pre>
 
=={{header|Java}}==
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.