Skip to content

Huffman Coding

  • A compression algorithm that uses the concepts from Optimal Merge Pattern.
  • Huffman coding is a variable size encoding.

Usually each alphabet in ASCII takes 8-bit.

Message to transmit: ACCBDAECCDAE

Alphabets ASCII
A 65
B 66
Alphabets Count Frequency Code
A 3 3/12
B 1 1/12
C 4 4/12
D 2 2/12
E 2 2/12