GE interview question

remove a duplicate from an array