Problem Statement
When would you prefer composition over inheritance? Name two scenarios.
Explanation
When reusing behavior without inheriting unwanted API; when behavior needs to vary at runtime (strategy pattern); to avoid fragile base-class coupling.