Pregunta de entrevista de Microsoft

Some string manipulation problem like finding a substring.