RBC interview question

Basic OOPs questions and code review