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

Piet van Oostrum piet at cs.uu.nl
Sun Feb 9 10:36:19 EST 2003


>>>>> aahz at pythoncraft.com (Aahz) (A) wrote:

A> From my POV, usable orthogonality is related to simplicity.  Adding a
A> ternary operator reduces Python's simplicity, and therefore a certain
A> amount of orthogonality.  Listcomps fit "practicality beats purity", but
A> I just don't see that *in* *the* *aggregate* for ternaries.

I think conditional expressions add to the orthogonality. You have
expressions and statements in Python, but statements can be conditional
and expressions cannot. This is unorthogonal. Algol 68 was orthogonal in
this respect, what you could do in statements was the same as what you
could do in expressions (there being no difference).
-- 
Piet van Oostrum <piet at cs.uu.nl>
URL: http://www.cs.uu.nl/~piet [PGP]
Private email: P.van.Oostrum at hccnet.nl




More information about the Python-list mailing list