Pergunta de entrevista da empresa PIMCO

Coding challenge by using the language you prefer.