[docs] [issue16225] list.remove in for loop

Chris Jerdonek report at bugs.python.org
Sun Oct 14 09:36:47 CEST 2012

Chris Jerdonek added the comment:

> I have worked with languages where you are explicitly warned that you must not mess with the loop variable

There is a warning in this part of the tutorial:

"It is not safe to modify the sequence being iterated over in the loop..."

(from http://docs.python.org/dev/tutorial/controlflow.html#for-statements )

But it may be good to add a note to the section you reference as well.

assignee:  -> docs at python
components: +Documentation
nosy: +chris.jerdonek, docs at python

Python tracker <report at bugs.python.org>

More information about the docs mailing list