On Tue, Jun 25, 2013 at 5:52 AM, <jim...@aol.com> wrote: > (NOTE: Many people are being taught to avoid 'break' and 'continue' at all > costs...
Why? Why on earth should break/continue be avoided? I think that's the solution: teach people that loops are there to be interrupted and manipulated. And then it's a small step to jumping into the middle of a loop, and from there to Duff's Device... hmm, I'm not sure that strengthens my case, really. But anyway. Python has no issues with breaking out of loops, and even has syntax specifically to complement it (the 'else:' clause). Use break/continue when appropriate. ChrisA -- http://mail.python.org/mailman/listinfo/python-list