Chain-Sys interview question

Remove duplicate elements in an array