Pergunta de entrevista da empresa Source Intelligence

Which would you prefer: composition or inheritance?

Resposta da entrevista

Sigiloso

4 de fev. de 2016

I prefer composition over inheritance - one of the design principles of OOP. I also find it easier to re-use code and it's easier for the developer to digest.