Frage im Vorstellungsgespräch bei Capgemini Engineering

Write a code to remove duplicate from an array.

Antwort im Vorstellungsgespräch

Anonym

17. Jän. 2019

Integer[] a= {1,2,2,3,4,4,5,7,7}; HashSeth=new HashSet(); for(int i:a) { h.add(i); } System.out.println(h); }