Article View: comp.lang.misc
Article #5343Re: Readable names
From: Barry Margolin
Date: Mon, 21 Mar 1988 20:49
Date: Mon, 21 Mar 1988 20:49
24 lines
1533 bytes
1533 bytes
In article <2779@mmintl.UUCP> franka@mmintl.UUCP (Frank Adams) writes: >In article <2857@enea.se> sommar@enea.UUCP(Erland Sommarskog) writes: >> But if you mean to imply that NumOfAcc would be better than >>NumberOfAccidents, I have to object. > >I don't much care for either of these alternatives. Looking at the words >here, 'Number' is convention and should be abbreviated, 'Of' is >superfluous, and 'Accidents' contains the meat of the name. (Just to keep >things down, I would omit the final 's' here, since it can be inferred from >the 'Number' prefix.) This gives us NumAccident or nAccident, depending on >which convention you use for 'Number'. Another thing to take into account is context. If this variable is being used in a program that deals with insurance claims, the abbreviation "Acc" for "Accident" would be pretty clear from the context. In another program, it might be necessary to spell it out to avoid ambiguity. Barry Margolin Thinking Machines Corp. barmar@think.com uunet!think!barmar
Technical Details
Message-ID:
<18347@think.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!necntc!ima!think!barmarReferences:
<2318@bsu-cs.UUCP> <2835@enea.se> <1810@sics.se> <25548@cca.CCA.COM> <2857@enea.se> <2779@mmintl.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!necntc!ima!think!barmar From: barmar@think.COM (Barry Margolin) Newsgroups: comp.lang.misc Subject: Re: Readable names Message-ID: <18347@think.UUCP> Date: 21 Mar 88 20:49:32 GMT References: <2318@bsu-cs.UUCP> <2835@enea.se> <1810@sics.se> <25548@cca.CCA.COM> <2857@enea.se> <2779@mmintl.UUCP> Sender: usenet@think.UUCP Reply-To: barmar@fafnir.think.com.UUCP (Barry Margolin) Organization: Thinking Machines Corporation, Cambridge, MA Lines: 24