Especially when you finally figure out inheritance and OO you fall in to that "when all you have is a hammer".
Composition is not an obvious way to approach this problem when you've been taught to solve problems with inheritance - and it fits "so nicely".
Especially when you finally figure out inheritance and OO you fall in to that "when all you have is a hammer".
Composition is not an obvious way to approach this problem when you've been taught to solve problems with inheritance - and it fits "so nicely".