primitive types to ArrayList any other way to do it?
int[] arr = {1,2,3};
ArrayList<Integer> l = new ArrayList<Integer>(Arrays.asList(arr));
ArrayList<Integer> list = new ArrayList<Integer>(Arrays.asList(1,2,3,4));
Nothing wrong excerpt that it doesn't do any conversion. Check this: https://docs.oracle.com/javase/8/docs/api/java/lang/String.html#join-java.lang.CharSequence-java.lang.Iterable-
Обсуждают сегодня