How to break out of two nested for loops?
Aahz Maruch
aahz at panix.com
Mon Jan 21 21:08:01 EST 2002
In article <shfp4uk9mhavveieacp0q2vjvuahn5dif6 at 4ax.com>,
Dale Strickland-Clark <dale at riverhall.NOTHANKS.co.uk> wrote:
>Tom Jenkins <tjenkins at devis.com> wrote:
>
>>
>>well an easy way to break out of n loops is using an exception.
>
>This solution keeps cropping up but, IMHO, using an *exception* for
>something that isn't an exception is just as obscure, misleading and
>awkward as a goto.
That's an attitude. It's an incorrect attitude, but it's one you share
with a fair number of people. You might want to check up on the
workings of the for loop.
--
--- Aahz <*> (Copyright 2002 by aahz at pobox.com)
Hugs and backrubs -- I break Rule 6 http://www.rahul.net/aahz/
Androgynous poly kinky vanilla queer het Pythonista
"I support family values -- Addams family values" --www.nancybuttons.com
More information about the Python-list
mailing list