Can I build a dictonary with a list-comprehension?
Magnus Lie Hetland
mlh at idi.ntnu.no
Mon Sep 3 16:11:20 EDT 2001
More information about the Python-list mailing list
Mon Sep 3 16:11:20 EDT 2001
- Previous message (by thread): Can I build a dictonary with a list-comprehension?
- Next message (by thread): Formatting question : printing numbers with thousands separators ?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
"Hans Nowak" <hnowak at cuci.nl> wrote in message news:mailman.999504963.22471.python-list at python.org... > Un an entirely unrelated note, maybe there should be dictionary > comprehensions, too... :) > > { k,v for k,v in dict if type(v) == type("") } > > <ducking for cover> I suggested this quite a while ago, but it didn't catch on. -- Magnus Lie Hetland http://www.hetland.org "Reality is that which, when you stop believing in it, doesn't go away." -- Philip K. Dick
- Previous message (by thread): Can I build a dictonary with a list-comprehension?
- Next message (by thread): Formatting question : printing numbers with thousands separators ?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list