Pregunta de entrevista de Cognizant

Based on basic programming