[issue41454] while loop bug on list
Eric V. Smith
report at bugs.python.org
Sat Aug 1 09:45:17 EDT 2020
Eric V. Smith <eric at trueblade.com> added the comment:
You're mutating the list while iterating over it, which is causing the behavior you're seeing. This isn't a bug.
See for example https://stackoverflow.com/questions/6260089/strange-result-when-removing-item-from-a-list
Also, when reporting bugs in the future, please include the output you got, and how it differs from what you expected. It's difficult to guess.
----------
nosy: +eric.smith
resolution: -> not a bug
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41454>
_______________________________________
More information about the Python-bugs-list
mailing list