PEP 308: ternary operator

Jarek Zgoda jzgoda at
Fri Feb 21 22:21:16 CET 2003

Sheila King <usenet at> pisze:
> I also prefer the construct
> (true-expr) when (cond-expr) else (false-expr)

Where it comes from?
I think that more "natural" would be:
when (cond-expr) then (true-expr) else (false-expr)
or am I dumb T-SQL programmer?!
(I'm recalling the 'case when (cond) then (expr) else (expr)' syntax of

Jarek Zgoda                            JID:jarek at

More information about the Python-list mailing list