The document discusses Shannon's algorithm for constructing variable length binary codes for message symbols based on their probabilities. It provides an example of applying the algorithm to encode 4 message symbols with probabilities 0.4, 0.3, 0.2, 0.1. The algorithm involves listing symbols by decreasing probability, computing cumulative probabilities, determining codeword lengths, expanding probabilities into binary, and assigning codewords. The average code length is 2.4 bits/symbol and entropy is 1.84644 bits/symbol.