Pergunta de entrevista da empresa IBM

An average difficulty python algorithm question