programming-languageクラス親クラスのコンストラクタを呼ぶ(super)On this page親クラスのコンストラクタを呼ぶ(super) Python pyclass B(A): def __init__(self): super().__init__() # Python3 Python2 の場合は pyclass B(A): def __init__(self): super(B, self).__init__() 親クラス(かその上の方)で object を継承していないと TypeError: must be type, not classobj みたいなエラーが出るよ Swift swiftsuper.init(..) 📩 ご意見・ご感想はこちらから