Domanda di colloquio di Squelch

Inheritance VS composition: pros and cons.

Risposta di colloquio

Anonimo

21 gen 2019

Inheritance should be used only if we can describe a relationship with a phrase like "X is a Y", like "student is a person". In all other cases composition/aggregation should be used.