Skip to content

Instantly share code, notes, and snippets.

@Tony363
Created October 31, 2019 11:10
Show Gist options
  • Save Tony363/d9fc2105368cab7bceea9e1062c118c5 to your computer and use it in GitHub Desktop.
Save Tony363/d9fc2105368cab7bceea9e1062c118c5 to your computer and use it in GitHub Desktop.
class A:
def test(self):
print("test of A called")
class B(A):
def test(self):
print('test of B called')
super().test()
class C(A):
def test(self):
print("test of C called")
super().test()
class D(B,C):
def test2(self):
print("test of D called")
obj = D()
print(obj.test())
print(obj.test2())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment