Pregunta de entrevista de OpenText

coding question using array manipulation and string manipulation