1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
class A: @staticmethod def __new__(cls): print("A.__new__") return super(cls, A).__new__(cls) def __init__(self): pass def meth(self): pass #print(A.__new__) #print(A.__init__) a = A() #print(a.meth) #print(a.__init__) #print(a.__new__)