gmcm at hypernet.com
Wed Nov 24 14:05:24 CET 1999
Gareth McCaughan says (among other things):
> Mark Carroll wrote:
> > Basically, I'd be really interested to learn: what _don't_
> > people like about Python?
> - if/then/else works on *statements* (strictly, suites of
> statements) rather than on *expressions*, so I can't
> print "You scored %s point%s" % (score, if score==1 then ""
> else "s")
> or anything like that. (Or, as some people prefer to put it,
> Python has no ? : operator.)
>>> def p(score):
... print "You scored %d point%s" % (score, score==1 and ' '
You scored 1 point
You scored 3 points
More information about the Python-list