Publicis Sapient interview question

Inheritence vs Composition