"is" and ==

BlueJ774 jaysherby at gmail.com
Wed May 30 01:49:50 EDT 2007


Can someone please explain to me the difference between the "is"
keyword and the == boolean operator.  I can't figure it out on my own
and I can't find any documentation on it.

I can't understand why this works:

    if text is None:

and why this always returns false:

    if message is 'PING':

even when message = 'PING'.

What's the deal with that?




More information about the Python-list mailing list