Question OOP-INH-0056
MediumWhich relationship test suggests inheritance is appropriate?
- A.
The classes are in the same file
- B.
The subclass needs one method of the parent
- 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
Inheritance question
Which relationship test suggests inheritance is appropriate?
The classes are in the same file
The subclass needs one method of the parent
Sign up free to see the answer and a step-by-step explanation.
The parent has many fields
The subclass truly 'is a' kind of the parent and can replace it everywhere