Amdocs interview question

Javascript Nodjes Reactjs Remove duplicate elements from array without using set and hashmap