Pergunta de entrevista da empresa JPMorganChase

Leetcode easy, nothing difficult really