class Father: def f1(self): print('hello')class Son(Father): def f1(self): super(Son, self).f1() # super格式:(子类,对象).重写的方法 print('world')obj = Son()obj.f1()