dictionary with order?

Matt Gerrans mgerrans at mindspring.com
Fri Mar 14 18:57:22 CET 2003


Do you just want shorthand for something like this:

keys = dictionary.keys()
keys.sort()
zip( keys, [d[key] for key in keys] )








More information about the Python-list mailing list