Pregunta de entrevista de Paralaxiom

problem based on string. (easy level)