Pregunta de entrevista de Magenic

Write a function to remove duplicates from an array.