Question OOP-INH-0018
HardWhen should composition be preferred over inheritance?
- A.
When the relationship is HAS-A, or behaviour needs to vary without a rigid class hierarchy
- B.
Only when classes are final
- C.
Sign up free to see the answer and a step-by-step explanation.