KPIT Technologies interview question

Oops concepts