class ParentClass(object):
def __init__(self):
self.__x = 1
self.y = 10
def PRINT(self):
print (self.__x, self.y)
class ChildClass(ParentClass):
def __init__(self):
super(ChildClass, self).__init__()
self.__x = 2
self.y = 20
c = ChildClass()
c.PRINT()
Why is the output (1, 20)? I know how I got 20, but shouldn't it be 2 instead of 1?