ungleich-learning-circle/youngjin.han/python-the-hard-way/ex44b.py

16 lines
224 B
Python
Raw Normal View History

2020-06-17 13:25:02 +00:00
class Parent(object):
def override(self):
print("PARENT override()")
class Child(Parent):
def override(self):
print("CHILD override()")
dad = Parent()
son = Child()
dad.override()
son.override()