|Don't ask to ask, just ask|
A forget-me-not to remind me to remember not to forgetby davies (Prior)
|on Nov 27, 2007 at 12:39 UTC||Need Help??|
... with apologies to Benny Hill!
Last night, someone in the chatterbox was asking about xcopy, and I produced a line from my backup batch which did - I think - everything needed. Certainly it does everything I need. An inoffensive comment was made about how ridiculous the line in question looked. I commented that, since it was past midnight, I couldn't remember and wasn't going to look up the meaning of every option.
Lying awake in the small hours, I remembered for no good reason the cobol compiler options we once discussed when I was at University 30 years ago. There were two schools of opinion on which worked better - ARSE or SEX. These are the sorts of games with compiler options that can amuse teenagers. However, the point is that I can remember both those sets of options, which is best and why, and what each one bar one (E - it did something mildly beneficial, but wasn't essential) does. It's not much use - I can't see anyone asking me to punch cards for a Univac 1110 again, but I do remember those compiler options, and don't remember the options for the Fortran and Pascal compilers.
A week ago, I was playing bridge, and before play, I was asked by a couple of friends about various conventions. In both cases, I was able to quote mnemonics to help them from books written by Ron Klinger. He also writes about how to play your cards in such an order that the enemy have the greatest difficulty in remembering. So my question applies to a wider world than just Perl or computing.
Learning Perl, 3rd Edition, By Randal L. Schwartz and Tom Phoenix says that $ and @ were chosen so that they could be read as $calar and @rray. Perl clearly has its obfu devotees, but what about the reverse of this (let's call it "ufbo"). While things like sensible names, comments and indentation are relatively old hat, what other techniques are used to make it easier for (a) the programmer, (b) the fabled maintenance programmer, and (c) the user to remember what things do? The Benny Hill line I used as the title and the cobol compiler options are permanently embedded in what passes for my brain. I'd like to get more useful stuff to stick, too.
For the sake of completeness, the xcopy command was:
xcopy c:\ m:\c /e /c /h /r /k /y
and I still don't remember what all the options are!