× 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.



Not to start a debate on the merits of GOTO, however
<snip>
C           SHDCTO    IFGT 1
C                     GOTO END
C                     ELSE
C                     Z-ADD1         COUNT
C                     END
C           END       TAG
<endsnip>
I'll grant you that the GOTO/TAG combo on such structured code is silly. 
However, using an ELSE on such simple logic is not.  It allows room for 
growth in the future.  In fact I've gotten away from using IF's in less 
than the most rudimentary cases.  The SELECT logic is much more flexible 
than having to modify your ELSE constructs.
Select;
When shdcto >= 1;
  count=1;
EndSl;
Actually, that is only one line of code more than:
If shdcto>=1;
  count=1;
EndIf;
However, it is much cleaner than nested if's/else's; allowing for 
modifications and code growth.

And I bet that the compiler never executes the Select statement, so those 
of you monitoring nanoseconds probably don't have a concern.

Rob Berendt
-- 
"Seek first to understand"
Stephen Covey "Seven Basic Habits of Highly Effective People"


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.