What relationship does public inheritance normally express?
-
A
A has-a relationship between the classes
-
B
A uses-a relationship between the classes
-
C
A part-of relationship between the classes
-
D
An is-a relationship between the classes
Correct answer
Correct answer
D. An is-a relationship between the classes
15 views
Explanation
Public inheritance models is-a, so a derived object can stand in wherever a base object is expected.
Reference
Asked in: NTS, PPSC IT, Campus Interviews
Doubts & discussion
Not sure why the answer is D? Ask here and get an explanation.
Ask a doubt about this MCQ