mapping None values to ''

imho certo at
Mon Jun 19 16:50:31 CEST 2006

Roberto Bonvallet ha scritto:
> imho <certo at>:
>> map(lambda x:"" , [i for i in [a,b,c] if i in ("None",None) ])
> You don't need map when using list comprehensions:
>    ["" for i in [a, b, c] if i in ("None", None)]

I know that... I tried to match the idiom used by the o.p. :-)

More information about the Python-list mailing list