Removes duplicate elements.
Array: Location of the list to check for duplicates
Output-location: Location to store the output data