How to break out of two nested for loops?

Laura Creighton lac at strakt.com
Fri Jan 25 15:16:47 EST 2002


> On Thu, 24 Jan 2002 17:27:31 +0100, Laura Creighton <lac at strakt.com> wrote:
> What made you think of 'discover'?

Ah, that is back to the nature of creativity.  What happened was that
I thought about a lot of words last night, and much of last week
actually, but nothing caught fire.  Then, on the tram, on the way
from COMDEX, reading a flashy brochure about a secure web solution
which, as far as I can tell from the brochure, _isn't_ ... my brain
just went *ping*

And, I got 'discover would be a nice word for it' immediately followed
by 'that is not an intermittant NFS problem, that is a problem with
cpickle!' (another problem I have been thinking about.  it was.)  
Perhaps I was thinking 'I just discovered a major security hole in 
their implementation which will leave these people in a nice pickle' but 
I don't think so.

The good news is that if my having insights depends on having
insecure web solutions in Sweden, it looks like I am set for a while.

> How about catch ;-)
> Or plain 'on' ?
> 
> try:
>    f=open('xxx','r')
> on IOError, e:
>    print e

Well, to tie this to the 'why colons thread' --Jacob Hallén, (jacob at strakt.com)
suggested:

try:
    do something
 surprise!	(<-- note no colon)
    do something else
   

(this sort of defeats the purpose I was after ... )

Laura Creighton





More information about the Python-list mailing list