java increase arraylist size code example Example: java create arraylist with size ArrayList arr=new ArrayList(10);