On Wed, Mar 16, 2016, at 11:17, Sven R. Kunze wrote: > I can imagine that. Could you describe the general use-case? From what I > know, "else" is executed when you don't "break" the loop. When is this > useful?
for item in collection:
if good(item):
thing = item
break
else:
thing = default # or raise an exception, etc
--
https://mail.python.org/mailman/listinfo/python-list
