Pregunta de entrevista de Nokia

Why do we need inheritance, when we can achieve the same using aggregation in c++?