Experiment
Data Compression
How does LZ77 compression shrink data? It slides a window over text, finds repeated patterns, and replaces them with references to earlier occurrences. Watch the algorithm discover structure in your text, character by character.
Input text — search window / lookahead buffer
Compressed output (tokens)
Match dictionary
| # | Pattern | Offset | Length | Saved |
|---|