ALEX Interview Question

Contain duplicate array, return index