human
How do I iterate over a Python dictionary, ordered by values?
assistant
Here is some code to sort dictionary `dictionary` in ascending order by its values

sorted(list(dictionary.items()), key=operator.itemgetter(1))

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.