how to set the values of an array to an arraylist in java code example Example: Create ArrayList from array java new ArrayList<>(Arrays.asList(array));