java int array to integer arraylist

Solutions on MaxInterview for java int array to integer arraylist by the best coders in the world

showing results for - "java int array to integer arraylist"
Camilla
12 Oct 2018
1//only works in java 8 or later
2list.stream().mapToInt(i -> i).toArray();
Lisa
24 Apr 2019
1int[] ints = {1, 2, 3};
2List<Integer> intList = new ArrayList<Integer>(ints.length);
3for (int i : ints)
4{
5    intList.add(i);
6}
7
Klara
15 Jan 2018
1list.stream().mapToInt(i -> i).toArray();
similar questions
queries leading to this page
java int array to integer arraylist