For review: PEP 308 - If-then-else expression
Andrew Koenig
ark at research.att.com
Tue Feb 11 13:55:43 EST 2003
Samuele> "Andrew Koenig" <ark at research.att.com> ha scritto nel
Samuele> messaggio news:yu99n0l2pvtj.fsf at europa.research.att.com... I
Samuele> don't like the naive questions that if: else: statement
Samuele> vs. if: else: conditional expression could generate.
>> Such as?
Samuele> You should not assume that people have done their homework
Samuele> when they ask this kind of thing or that they have a firm
Samuele> grasp of the conceptual framework of things, people typically
Samuele> come with "why this does not work?" and you think: it is
Samuele> clear that it cannot work.
In other words, it is clear to you. However, you might be mistaken.
Samuele> (if x>0: print "positive" else: print "negative")
Samuele> (for x in l: print x)
I have solved that problem. Details shortly.
--
Andrew Koenig, ark at research.att.com, http://www.research.att.com/info/ark
More information about the Python-list
mailing list