Pergunta de entrevista da empresa Agoda

Solve the longest consecutive sequence problem