Cognizant Interview Question

about java and oops concepts