yomgui <[EMAIL PROTECTED]> writes: > is it legal to return inside a for loop > or am I obliged to break out of the loop before returning ?
Try it and see: >>> def f(): ... for i in range(20): ... if i > 10: return i ... >>> print f() 11 >>> <mike -- Mike Meyer <[EMAIL PROTECTED]> http://www.mired.org/home/mwm/ Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information. -- http://mail.python.org/mailman/listinfo/python-list