How can I add multiple items at once to an ArrayList?
ArrayList<Integer> integerArrayList = new ArrayList();
Instead of:
integerArrayList.add(1)
integerArrayList.add(2)
integerArrayList.add(3)
integerArrayList.add(4)
...
I would like to: integerArrayList.add(3, 1, 4, 2);
So that I wont have to type so much. Is there a better way to do this?