📅  最后修改于: 2022-03-11 14:52:32.636000             🧑  作者: Mango
Listnumbers = Arrays.asList(1,2,2,2,3,5); // [1, 2, 3, 5]
System.out.println(numbers);
Set hashSet = new LinkedHashSet(numbers);
ArrayList removedDuplicates = new ArrayList(hashSet);
System.out.println(removedDuplicates); // [1, 2, 3, 5]