For review: PEP 308 - If-then-else expression

Samuele Pedroni pedronis at
Mon Feb 10 03:55:13 CET 2003

"Andrew Koenig" <ark at> ha scritto nel messaggio
news:yu997kc8ooli.fsf at
> I'd be happy with
>         true_expr if cond else false_expr

I don't like the order.

> but must confess that I'm growing more in favor of
>         if cond: true_expr else: false_expr

I don't like the : in there.

I could live with something of the form:

Cond KEYW-TO-PICK true_expr else false_expr

but KEYWord is still to pick.

More information about the Python-list mailing list