object identity and hashing

castironpi at gmail.com castironpi at gmail.com
Mon Feb 25 02:39:46 CET 2008


Can someone explain this?

>>> a= {}
>>> a[(3,)]= 0
>>> (3,) in a
True
>>> (3,) is (3,)
False



More information about the Python-list mailing list