I am writing a mapping object, and I want to ask about the details of __hash__ and __eq__. IIUC if I understand correctly, the Python dict's keys' hash codes are looked up first in O( 1 ), then all the matching hash entries are compared on equality in O( n ). That is, the hash code just really narrows down the search. Am I correct?
P.S. I always feel like my posts should start like, "A mapping object am writing I." Not too many verbs you can do that with in English. What if I did it? -- http://mail.python.org/mailman/listinfo/python-list