[Info] PEP 308 accepted - new conditional expressions
Sam
sam at email-scan.com
Fri Sep 30 18:53:47 EDT 2005
Reinhold Birkenfeld writes:
> Hi,
>
> after Guido's pronouncement yesterday, in one of the next versions of Python
> there will be a conditional expression with the following syntax:
>
> X if C else Y
>
> which is the same as today's
>
> (Y, X)[bool(C)]
What's wrong with "C ? X:Y"?
Aside from ":" being overloaded?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-list/attachments/20050930/ec19ef59/attachment.sig>
More information about the Python-list
mailing list