Infosys Interview Question

Basic java understanding