Pregunta de entrevista de IBM

The question can be based on string and array