Looping redux. was: do ... while loop

James Logajan JamesL at Lugoj.Com
Wed Oct 13 23:32:28 EDT 1999


Alexander Williams wrote:
> Python is designed to minimize the syntactic sugar poured in the
> gas-tank of your coding; "do ... while" truly is only a syntactic
> abstraction for an initialized while loop
[...]
> Its not that
> much more typing, the test is very clearly marked at the top of the
> structure, and we have the benefit of a single, consistant means of
> presenting the loop rather than thirteen varying ones.

Every control structure is mere syntactical sugar for the elegantly simple
"if <cond> goto <label>" and "goto <label>" control statements. And in a
heartbeat I could get by with the use of the bare "if" form by doing "if
true goto <label>" where needed.

Therefore, I propose the following:

thefuture: if version == python2 goto thefuture

So there.




More information about the Python-list mailing list