Another conditional expression candidate (PEP 308)
Roy Smith
roy at panix.com
Sun Feb 9 20:52:54 EST 2003
I wrote:
>> Why is the else: manditory? Why not have it return None if none of
>> the
>> conditions are true? It seems natural, and makes the syntax even more
>> like the current if statement.
Erik Max Francis <max at alcyone.com> wrote:
> Explicit is better than implicit. After all, is "else: None" (or "else
> None" in the original PEP) _really_ too much to type?
If "else: pass" isn't required in the statement, why should "else: None"
be required in the expression?
More information about the Python-list
mailing list