Steven D'Aprano <steve at REMOVE.THIS.cybersource.com.au> wrote: ... > while some_dict: > do_something_with(some_dict.pop()) > > doesn't work. Instead you have to write this: You have to use .popitem for this -- that's what's it's for... Alex