Re: Why (or not) use single letter variable names?

From: Shmuel (Seymour J.) Metz (spamtrap_at_library.lspace.org.invalid)
Date: 12/15/04


Date: Wed, 15 Dec 2004 12:45:54 -0500

In <EuSdnbZEZM1s5iDcRVn-qA@rcn.net>, on 12/13/2004
   at 10:46 AM, jmfbahciv@aol.com said:

>Some of the programmers I worked with (a long time ago) could type 60
>words/minute.

So little of the time involved in programming is spend writing the
actual code that the difference between, e.g., 12 wpm and 120 wpm is
irrelevant. Programmers typically use long names for two reasons:

 1. Local policy requires structured names

 2. They believe the resulting code to be more readable.

>The reason people use these things is to avoid documenting what
>they do.

The choice of names is an important part of the documentation. That
does not, of course, reduce the need for other documentation.

>A programmer who knows his biz will not have to read the purpose of
>a variable every time he needs to reference it in his code.

A programmer who knows his business will chose names that remind the
reader of their purpose.

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>
Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org


Relevant Pages

  • Re: I cant believe how complex this Format SDK is...
    ... technologies from low level interrupt programming to high-level user ... Sorry for any offence but I disagree. ... I find the documentation more than sufficient. ... -- In looking at profiles, am I even looking in the right place? ...
    (microsoft.public.windowsmedia.sdk)
  • Re: removing last chrs (with different browsers giving different last chrs )
    ... Documentation is just as important if you are going to be the only one to look at it. ... the best tool I've found for PHP programming is Crimson editor on Windows or vim on Linux. ... I don't have one function which tries to validate everything. ... This ensures the value is an integer and puts out a meaningful error message if it isn't. ...
    (comp.lang.php)
  • Re: I wonder if Windows REALLY support the C++ language
    ... Just to borrow from data structures and programming world ... so is the search time (and sometimes worse ... > So should have been with MS’ documentation – that is, ... The distinction is between GUI and console programming, ...
    (microsoft.public.vc.language)
  • Re: Beware wildcards in Kill
    ... as we "float" up into the sphere of advanced programming, the base constructs of what all is created from gets lost in the fog of ... > that documentation is often written by "technical writers" ... > who lack any real technical depth, ... > The only reason I happen to know the stuff I just told you ...
    (microsoft.public.vb.syntax)
  • Re: Designing PHP applications
    ... The type of advice would depend much on your programming background. ... bonus, when your documentation is structured and organized, the better ... Have a look at CVS. ... expecially one that has a gallery module... ...
    (comp.lang.php)