Capgemini interview question

OOPS concept and Java basics