Dictionary from list?

Andrew Dalke dalke at dalkescientific.com
Sat Oct 20 20:34:30 EDT 2001


Uncle Tim:
>but there are few core functions that produce such a list
>(dict.items(), zip() and some cases of map() are all that pop to mind), so
I
>had a hard time picturing a good use for that

Not a core function, but

args, files = getopt.getopt(...)
args = dictionary(args)

would be handy.

                    Andrew






More information about the Python-list mailing list