Infosys interview question

Puzzle and Reasoning.