Virtusa interview question

Technical was little bit tricky