TECH NEWS
Why Python Dictionaries Crash When You Add or Delete Keys While Looping
Here is a situation that is easy to run into: you have a dictionary of scores and one simple job, remove everyone below 50. Four lines of code, nothing fancy. Python answers with this: RuntimeError: dictionary changed size during iteration Try the same pattern on a list and it doesn&