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



On Tue, Nov 12, 2019 at 5:13 PM Craig Richards <craig@xxxxxxxxxxxxxxxx> wrote:

And if some maintenance programmer drops a READ into the loop?

It would only be a problem if he dropped his READ in between the last two
lines, in between the READE and the ENDDO.

They could drop in a read statement followed by ITER.

Then my version would work correctly and yours wouldn't.
That would be ironic - the very thing you put in to defend
against potential mistakes, caused an issue, where otherwise the code would
have been ok

I'm not 100% sure what you're envisioning, but if "not working
correctly" entails something very obvious (preferably a compile-time
error, but failing that, a run-time error, and failing that, hopefully
some kind of really, really blatant and easily visible wrong
calculations) then there's an argument to be made that it's a good
thing.

Obviously, there is no way to defend against everything. Sometimes,
making it harder to be *subtly* wrong is a win. (I mean that in
general. Whether your example is an illustration of this, I am not
sure, since I didn't fully follow it.)

John Y.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.