連載目次 単一継承 class B: def __init__(self, a): print(‘B init’) self.a = a def some_method(self): print(f’a: {self.a}’) class D(B): def __init__(self, a, b): print(‘D init’) super().__init__(a) self.b = b def another_method(self): self.some_method() print(f’b: {self.b}’) d = D(…