Pergunta de entrevista da empresa IBM

First step usually consist of Hackerank coding challenge but this time they changed.