I having a problem with coding this:
Write a static method named removeDuplicates that takes as input an array of integers and returns as a result a new
removeDuplicates
public class Test static int[] array = {4, 3, 3, 4, 5, 2, 4}; static HashSet list = new HashSet(); public static void main(String ar[]) { for(int i=0;i
The Output is : [2, 3, 4, 5]
[2, 3, 4, 5]