On Sun, 11 Apr 2010 21:35:49 -0700, Aahz wrote: > In article <mailman.1330.1269981186.23598.python-l...@python.org>, Steve > Holden <st...@holdenweb.com> wrote: >> >>It exists because people nagged Guido mercilessly until, against his >>better judgment, he capitulated. > > No, the ternary exists because he became convinced that it was the > lesser evil compared with letting the abomination of > > A and B or C > > remain the "Pythonic" ternary and someone came up with a syntax that > wasn't completely painful.
As I recall, Guido himself got bitten by a subtle bug in the A and B or C idiom for ternary operator. Namely, if B is a false value, you get C even if A is true. -- Steven -- http://mail.python.org/mailman/listinfo/python-list