From mboxrd@z Thu Jan 1 00:00:00 1970 From: dave@horsfall.org (Dave Horsfall) Date: Sun, 7 May 2017 04:43:33 +1000 (EST) Subject: [TUHS] Discuss of style and design of computer programs from a user stand point In-Reply-To: <20170506144011.GF28787@mcvoy.com> References: <201705060202.v4622L1J013430@coolidge.cs.Dartmouth.EDU> <5a2d6cc957c2efcd968f35aa5557c7a0e309dd27@webmail.yaccman.com> <20170506091857.GE12539@yeono.kjorling.se> <20170506144011.GF28787@mcvoy.com> Message-ID: On Sat, 6 May 2017, Larry McVoy wrote: > When I run engineering teams the point I make is if you wrote the code > more than 6 months ago it might as well be someone else's code. So > write it in a way that someone else can debug / extend it. A principle I've tried to follow over the years is "write code as though the next person to maintain it is an axe-wielding murderer who knows where you live". > I also made the point that "clever" sucks. At least most of the time. > All "clever" means is "hard to understand". The brief joy one gets from > clever code is stomped on by the frustration one gets from having to fix > it. Apropos the above, I do confess to writing "clever code" from time to time (PERL is a beautiful language for such sins)... Of course, in the olden days it was the APL "one-liners" :-) -- Dave Horsfall DTM (VK2KFU) "Those who don't understand security will suffer."