Question OOP-CTOR-0055
MediumIn Java, what is a constructor chain such as this(0, 0) used for?
- A.
Calling the parent's constructor
- B.
Creating two objects
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Constructors and Destructors question
In Java, what is a constructor chain such as this(0, 0) used for?
Calling the parent's constructor
Creating two objects
Sign up free to see the answer and a step-by-step explanation.
Destroying an object
Calling another constructor of the same class to reuse its setup