Huffman encoding

Creator
Creator
Seonglae ChoSeonglae Cho
Created
Created
2023 Nov 2 6:37
Editor
Edited
Edited
2023 Nov 2 6:43
Some characters are more frequent than others and for them we can uses only one or two bits
notion image
 
 

Steps

  1. Calculate a frequency for each node
  1. Connect smallest numbers
    1. notion image
  1. Assign 0 to left branches, 1 to right branches
  1. Each encoding is a path from the root
    1. notion image
 
 
 
 
 
 
 

Recommendations