Find the first duplicate number code has been added

Find the first duplicate number in a given integers array.