The following is a program I wrote in C++ that helped me crack the bonus problem. It does frequency analysis and offers two different frequency tables based off of different sized dictionaries.
You can input an A-to-Z cipher decryption, or an m,b affine cipher value. You can also enter single letter substitutions and view the results live. This program follows the book's convention that plaintext letters are lowercase and encrypted letters are uppercase.
The flexibility and speed that I could try substitutions allowed me to solve the bonus problem with ease. It largely fell apart when I tried "and" immediately following the comma. Unfortunately my two pre-programmed frequency tables were of little help.
Note: User input is VERY picky. Inputting the wrong thing may result in an infinite cin loop, at which point you will have to close the program. This program is largely for my own personal use, hence the very rough edges.
View Source Code:
Download compiled Windows Binary with Source.
Return to Mike Miller's MA454 main page.