Roy Smith wrote:
Hans Georg Schaathun <h...@schaathun.net> wrote:
If both are numbers, they are converted to a common type. Otherwise, objects of different types always compare unequal

That's just the default treatment for unrelated types that don't
know anything about each other.

I would guess that the list's == method is asking "Is the
other object a list?", and since a subclass of list is also
a list, it's happy and goes on to compare the elements.

--
Greg
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to