× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




I have no problem with Scott's logic, maybe because I have no no
presumptions about what it might be doing.


Oh please (ROFL!). That sounds like someone saying that global warming
is causing record snowfalls. It's the sort of non sequitur

How one gets from that to the other is far beyond me! But OK.

But thank you for making my argument for me: it's not the use of "not"
that makes a program more or less readable, it's general common sense.
In this case, the variable name "Valid" is a particularly poor one
because it's not at all clear what "valid" means. But that's my
opinion, and that's the crux of the argument: programming is very much
about opinion, and style is in the eye of the beholder.

Clarity is seldom in the eye of the beholder. I do see your point. A flag
name like "ItemIsOnFile" or ItemNotOnFile or some such would be so much more
appropriate. More appropriate yet would be a procedure of same name e.g.
ItemNotOnFile(itemNumber) - but we've strayed so far from the original post
that it's no longer recognizable.

The original post was:

IF Not doThis
Return
EndIF
If Not doThat
Return
EndIF

My point was that it is clearer (and I still hold that it USUALLY is) to
say:
If doThis
If doThat
Xxxxx
EndIF
EndIF
Return

It also gives maintenance programmers less grief since there's no unexpected
RETURN up there where it doesn't belong.

And as far as that EXSR GET OUTNOW argument... that just hides the RETURN
from the maintainer more effectively. It is lazy, ugly, and asking for
trouble down the road (when the author is at some other job, creating new
problems for new followers).

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"God bless the Holy Trinity"
-- placard in a Dublin parade




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.