Sir Francis Bacon lived in Tudor/ Stuart times. He is best known for inventing the way we do science. He was also a spy for Queen Elizabeth I. As a teenager he invented a new kind of secret code, published in the year of the Gunpowder Plot. His idea is now used in all computers to represent letters.
Secret codes turn a message (the plaintext) into gobbledygook (the ciphertext). One way is to swap letters for other letters. This means no one can read them unless they know, or work out, the secret of what each symbol means. But if you have a line of letters that make no sense it’s pretty obvious you are looking at a secret message. Bacon wanted a way to hide the message too.
His code had two parts. He first swapped each letter of his secret message for a special code. He then hid these codes in any old sentence.
His code was to swap each letter of the alphabet for its own series of 5 a’s and b’s. For example, N became ‘abbaa’ and O became ‘abbab’. The secret message “NO” becomes abbaaabbab. The full code is here. This kind of code is how computers store letters, except we use 0 and 1 instead of ‘a’ and ‘b’. We call it binary!
Using a’s and b’s makes the message unreadable, but with a further step, it also gave Bacon a way to hide the message. He realised that any two things could be used in place of the a’s and b’s. For example, an a in the secret message could mean: write the next letter of some other harmless message as a capital letter, and a ‘b’ would mean write it as a lower-case letter. That meant he could hide his secret message in other writing. If you do this for every letter it still looks strange, but if you use the capitals rule only on the first letters of words it’s hard to see anything strange is going on.
Twinkle, twinkle, little Star,
How I wonder what You are!