Py3K idea: why not drop the colon?
Fredrik Lundh
fredrik at pythonware.com
Fri Nov 10 15:36:03 EST 2006
Bjoern Schliessmann wrote:
> Marc 'BlackJack' Rintsch wrote:
>
>> No it doesn't -- look again at the example given above. It's
>> legal syntax in Python but doesn't have the semantics implied by
>> the example.
>
> Sorry, I don't understand -- what is the difference between the
> example as it is and the implied semantics of it?
>>> color = "blue"
>>> if color == "red" or "green" or "yellow":
... print color, "is red or green or yellow"
...
blue is red or green or yellow
</F>
More information about the Python-list
mailing list