lambda and if
Emile van Sebille
emile at fenx.com
Mon Jun 12 07:31:42 EDT 2000
----- Original Message -----
From: matt <matt at virtualspectator.com>
> sneaky ... it's nice.
> might be nice to extend that with
> ["","big"][x[1] in ("big",)] so we can extend the 'yes'
set
>
> but extending it to using the actual match is a little
more difficult,
> i.e.
> x[1] in ("big","little","wide",) where the matched item
would be appended if
> it existed or else a blank
Wouldn't ["",x[1]][x[1] in ("big","little","wide",)] do it?
>
>
> thanks
> matt
>
Emile van Sebille
emile at fenx.com
-------------------
More information about the Python-list
mailing list