Integer[][] (int[] numbers) { List<Integer[]> list = new ArrayList<>(); for (int number : numbers) { Integer n = number; Integer[] integers = new Integer[]{n}; list.add(integers); } return list.toArray(new Integer[0][]); }