Re:The scope of index variables in Python's for loops
by cnvogel on Sunday January 18, 2015 @03:11PM
(#8908667)
Probably this stems from the typical C-way of error-reporting out of a for-loop, which is to terminate earlier than the "regular loop condition", and hence a second test for the loop-condition can easily be used to check for abnormal termination...
Whereas the Python version obviously doesn't make sense in a pythonesque program iterating over sets of elements.
[ Parent
| on HN ]
There are no comments on this comment yet.