Pascal Bourguignon <firstname.lastname@example.org> wrote:
| email@example.com (Rob Warnock) writes:
| > John Thingstad <firstname.lastname@example.org> wrote:
| > | The bad new is that finding loop invariants is fairly difficult with
| > | the imperative constructs (Hoare logic)
| > +---------------
| > Quite true, in the general case. Fortunately, almost all the loops
| > one tends to write in "normal" code have a small set of loop-invariant
| > patterns that work well. ...
| I don't understand. You mean some loops are written without their
| invariant explicited first? That's not how I was taught (in school)
| to write loops...
Please refer to the "Subject:" of this thread again. Many practicing
programmers didn't *take* computer science in school, and even of those
who did I daresay most were *not* exposed to writing loops properly,
that is, with loop invariants developed as a matter of course.
Rob Warnock <email@example.com>
627 26th Avenue <URL:http://rpw3.org/>
San Mateo, CA 94403 (650)572-2607