Pergunta de entrevista da empresa Simba Technologies

One simple algorithm question having to do with array manipulation.