Appeal for python developers
Torsten Bronger
bronger at physik.rwth-aachen.de
Sat Mar 5 09:47:36 EST 2005
Hallöchen!
BOOGIEMAN <BOOGIEMANPN at YAHOO.COM> writes:
> Please include "goto" command in future python realeses I know
> that proffesional programers doesn't like to use it, but for me as
> newbie it's too hard to get used replacing it with "while", "def"
> or other commands
Accordings to Stroustrup's C++ book, the only good reason for goto
statements in a language is to have it in computer-generated code.
I don't know whether programs generate Python, but I *think* that
even there "goto" can be avoided very easily.
Anyway, at our institute we control devices with HT Basic, and my
collegues have used lots of gotos, so I can understand that avoiding
them is somewhat inconvenient at the beginning. However, it's still
very easy to learn. Most gotos are disguised function calls, so
just copy the code in a "def". And loops can be translated to
"while"s almost trivially.
After a couple of days, it'll be even simpler than before.
Tschö,
Torsten.
--
Torsten Bronger, aquisgrana, europa vetus
More information about the Python-list
mailing list