Java: Why does my class automatically inherits constructor from superclass? [duplicate]
问题 This question already has answers here : Inheritance in Java - creating an object of the subclass invokes also the constructor of the superclass. Why exactly? (15 answers) Default constructors and inheritance in Java (11 answers) order of constructor calls in multilevel inheritance in java [duplicate] (4 answers) Closed 5 years ago . When I try the code on the bottom of this question, the output is: a a b a b c So this means that the constructor from B and C call the constructors from their