Why is lambda allowed as a key in a dict?

Daniel Fetchinson fetchinson at googlemail.com
Tue Mar 10 02:38:27 EDT 2009


On 3/9/09, bearophileHUGS at lycos.com <bearophileHUGS at lycos.com> wrote:
> See here Daniel Fetchinson:
>
> http://groups.google.com/group/comp.lang.python/browse_thread/thread/a973de8f3562675c
>
> But be quite careful in using that stuff, it has some traps.

Thanks a lot for all the helpful replies!
Yes, I should name the unnamed lambda function, or better, just use 'def'.

Cheers,
Daniel


--
Psss, psss, put it down! - http://www.cafepress.com/putitdown



More information about the Python-list mailing list