I still think all of these constructs as just sooo basic that if you can't
just read them either which way,  then you had better think about another
career.

 

From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Rex Gozar
Sent: 04 March 2011 14:09
To: U2 Users List
Subject: Re: [U2] Is this worth rewriting?

 

good comprehension = faster, accurate programming (that's programming,
not code execution)

We all want fast and accurate programming.  To improve comprehension,
you have to write code to (a) reveal its logical structure, and (b)
reveal the business rules implemented in the code.

Sorry, but structures like:

IF A:B:C NE '' THEN CUM(M) = A+B+C

(concatenating variables as a string, then performing numeric
operations on them) slows down the comprehension process.  And for
what benefit?  To me, that's just a lazy programmer that doesn't want
to type a few extra keystrokes.

Another structure caused a number of comments:

IF condition THEN statement ELSE
   other-statement
END

(inline THEN followed by block ELSE). It appears that some readers saw
the "#" in the condition and assumed an "If Not Not" structure at
first, missing the THEN.

I find it interesting that no one has commented on the fact that
CUM(M) gets conditionally reinitialized, and whether or not that is
important.  But it proves my points that neither the structure nor
business rules are clear within the OP's code.

You can have 2 years programming experience, or 20, it does not
matter.  Better structure and variable naming will vastly improve
program accuracy. (On the other hand, I could make this code really,
really fast if it didn't have to be accurate!)

rex
_______________________________________________
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users 

  _____  

No virus found in this message.
Checked by AVG - www.avg.com
Version: 10.0.1204 / Virus Database: 1435/3480 - Release Date: 03/03/11

_______________________________________________
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

Reply via email to