Pergunta de entrevista da empresa Goodreads

A question combining base conversion and string manipulation, was not too difficult.