IBM interview question

Polymorphism and encapsulation