using "else: interactive programme
n.estner at gmx.de
Sun Mar 26 16:01:09 CEST 2006
I guess the indention got mixed up in your post, if I try to run it, I
get error messages at each of the "else:" lines, because they're
"else" should be indented like the "if" it belongs to, e.g (using
underscores for spaces):
____print "well done"
____print "something else"
Make sure you're using tabs/spaces consistently across the whole file,
If I indent the else clauses correctly, I can run your script and it
behaves the way you expeced.
More information about the Python-list