EPAM Systems interview question

Related to Core and Adv Java