@@ -0,0 +1,519 @@
+import java.util.ArrayList;%0Aimport java.util.List;%0A%0Apublic class Solution %7B%0A%0A    public List%3CInteger%3E findDuplicates(int%5B%5D nums) %7B%0A%0A        List%3CInteger%3E duplicatesList = new ArrayList%3CInteger%3E();%0A%0A        for (int i = 0; i %3C nums.length; i++) %7B%0A%0A            int index = Math.abs(nums%5Bi%5D) - 1;%0A%0A            if (nums%5Bindex%5D %3C 0) %7B%0A                duplicatesList.add(Math.abs(index + 1));%0A            %7D else %7B%0A                nums%5Bindex%5D = -nums%5Bindex%5D;%0A            %7D%0A%0A        %7D%0A%0A        return duplicatesList;%0A%0A    %7D%0A%0A%7D%0A

Create : 442 Find All Duplicates in an Array