EPAM Systems interview question

POO with JavaScript under hood