0
Help plz 💔 I need java code "remove the duplicate elements in array" using only for /if/while 😫
x=[1,2,2,2,3,5,3] ==== x=[1,2,3,5]
2 ответов
+ 3
Just use a set and it will automatically remove duplicates.
example:
Set<T> mySet = new HashSet<T>(Arrays.asList(someArray));
0
with out set 💔😭 only for loop and if statement