Domanda di colloquio di ZapLabs

Given an integer array with duplicates, remove the duplicates from the array and return a new array.