OK I feel better. I was overcome with an urge to write some code. Now I have a program I should write. I want to combine my seating chart program (with pictures) with the program I use to randomly pick on students. I mean randomly pick who to call on. Whoops. But I don't have the time to work on that right now.
So I wanted a "toy program." I remembered that I had been playing with a simple Caesar cipher program (who else remembers ROT-13?) What I have long been meaning to do was to write a program that took a string and rotated it though all 25 possible rotations (26 puts it back the way it was) and build a list so that if you suspected a Caesar substitution you could test it to see how it was rotated. Fine.
So I took the code for rotating in the encoding program and made it a simple little string function. Added a loop to pass a string to the function with different values to rotate and put the result in a listbox. By reusing code I was done in about 10 minutes. And I have a toy program I will probably use once every couple of years and could probably find a web app that does the same thing in about the same time it took to write the code. But oh so much more satisfying.
Who knows - I might assign it as a programming assignment someday as well. BTW Mike Zamansky has a closely related (and probably more useful post) on his blog Rot13 - Gateway Drugs Techniques