私はPythonでクラスの継承を理解しようとしており、以下の継承を作成しました.
質問: クラス B を継承してメソッド A を呼び出すと、"Im method B" と出力されます..クラス A の methodA を呼び出しませんか?
class A(object):
def methodA(self):
print 'Im method A'
class B(A):
def methodA(self):
print 'Im method B'
class C(A):
def methodA(self):
print 'Im method C'
class D(B,C):
def methodA(self):
print 'Im method D'
def main():
x = D()
x.methodA()