Find the first duplicate

Sign in to test your solution.