Cognizant interview question

and gate