Multiple Inheritance in Python calling parent methods
class A:
def m(self):
print(f"m of A called")
class B(A):
def m(self):
print("m of B called")
super().m()
class C(A):
def m(self):
print("m of C called")
super().m()
class D(B,C):
def m(self):
print("m of D called")
super().m()
x = D()
x.m()
Gives the output
m of D called
m of B called
m of C called
m of A called
Why is m of A only called once? My assumption is that it should be called twice, once by B() and once by C().
I was expecting the A.m() method to be called and printed out twice, but it only shows up once.