Name: Anonymous 2011-01-13 14:13
If we have a classes, that have the same interface and can be used only in the same way, then aren't they the same classes?
If we have objects, that have the same state and have the same interface, then aren't they the same objects?
Look:
If we have objects, that have the same state and have the same interface, then aren't they the same objects?
Look:
class X:
def foo(self):
return 1
class Y:
def foo(self):
return 1
a = X()
b = Y()
c = Y()
print X == Y
print a == b
print b == cFalse
False
False