In 1951, David Huffman was an MIT graduate student facing a brutal ultimatum from his professor, Robert Fano: take a grueling comprehensive final exam, or solve a problem that had stumped the founding fathers of information theory—finding the absolute most efficient binary coding scheme possible.
After months of dead ends, Huffman was on the verge of giving up to study for the exam. He gathered his scrap papers to throw them into the wastebasket when the core insight struck him: don't build the code from the top down; build it from the bottom up.
By merging the least probable symbols first, he proved that a simple greedy algorithm could achieve optimal prefix-free compression. His method bypassed the flawed top-down heuristics of Claude Shannon and Robert Fano, giving birth to a foundational pillar of modern computing.