public static void fourSum(int[] input, int target) {
        Arrays.sort(input);
        List<String> result = new ArrayList<>();
        HashSet<String> hashSet = new HashSet<>();

        for( int i=0; i< input.length; i++) {
            for( int j = i+1; j< input.length; j++) {
                int k = j+1;
                int l = input.length -1;
                while(k < l) {
                    int sum = input[i] + input[j] + input[k] + input[l];

                    if(sum < target) {
                        k ++;
                    } else if(sum  > target) {
                        l --;
                    } else {
                        StringBuilder s = new StringBuilder();
                        s.append(input[i]+","+ input[j]+ ","+ input[k] + ","+ input[l]);

                        if(!hashSet.contains(s.toString())) {
                            result.add(s.toString());
                        }
                        k++;
                        l--;
                    }
                }
            }
        }

        for(String s : result) {
            System.out.println("Result:" + s);
        }

    }