Shift Ciphers
Encrypts, decrypts and breaks four monoalphabetic ciphers: Caesar (shift 1–25), ROT13, Atbash and affine, E(x) = (ax + b) mod 26 with gcd(a, 26) = 1. Brute force lists all 25 shifts, auto-detect ranks them by chi-squared against English, and the affine solver tries all 312 keys. Suetonius (Julius 56) says Caesar wrote D for A, a shift of three; Rashi reads Sheshach in Jeremiah 25:26 as Babel by Atbash.
- Suetonius, The Life of Julius Caesar 56.6, trans. J. C. Rolfe (Loeb Classical Library, 1914), LacusCurtius
- Rashi on Jeremiah 25:26, Sefaria
- David Kahn, The Codebreakers: The Story of Secret Writing (New York: Macmillan, 1967)