sorting a dictionary

Rene Pijlman reageer.in at de.nieuwsgroep
Wed Feb 19 18:32:20 CET 2003


user at domain.invalid:
>Suppose I have dictionary (associative arry) with people's names and
>ages, like
>
>     names = {"Bob":27, "Larry":35, "Curly":65, "Moe":66, "Jeff":31,
>              "Guido":34, "Parrot":36}
>
>How can I sort this? 

This is explained in:
http://www.python.org/peps/pep-0265.html

-- 
René Pijlman

Wat wil jij leren?  http://www.leren.nl




More information about the Python-list mailing list