Longest consecutive sequence problem.