For review: PEP 308 - If-then-else expression
Erik Max Francis
max at alcyone.com
Sun Feb 9 15:57:27 EST 2003
Evan wrote:
> t = (if "spam" not in s: "customer"
> elif "eggs" in s: "vikings"
> else: "waitress")
This was one of the forms I suggested way back when.
--
Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
__ San Jose, CA, USA / 37 20 N 121 53 W / &tSftDotIotE
/ \ Life is an effort that deserves a better cause.
\__/ Karl Kraus
Alcyone Systems / http://www.alcyone.com/
Alcyone Systems, San Jose, California.
More information about the Python-list
mailing list