ELI5: Explain Like I'm 5

huffman tree

A Huffman tree is a type of diagram that is used to compress data. It works by taking all of the words or letters in a message and organizing them from most common to least common. The most common letter or word is put at the top of the tree and the least common at the bottom. By having the most common words or letters near the top of the tree, it is easier to compress the data into a smaller file that takes up less space.