Infosys interview question

Simple puzzles.