On www.enigmaco.de there is an interactive simulator of the German Enigma machine that was used during World War II to encode messages sent to the u-boot fleet. The story of how the British found an inegenious way of decoding these messages at Bletchley park, and through a paintstaking process based on human calculation (the original, mostly femal, calculators), is one of triumph of intelligence. The effort was a concrete aid to the allied effort, and shortened the war.
Cryptography is a fascinating subject, of cunning intelligence, and a great cultural analogy to what the spontaneous, but often as difficult encoding of natural laws is.
One of the best books of fiction about the subject is Neal Stephenson’s Cryptonomicon.