Privacy Policy Terms Of Use. Copyright © 2006-2010 Java Tutorials and Examples.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
I would like to know what is the default size of ArrayList? Also, what is the default initial capacity of an ArrayList.
Is there any method to increase the capacity of the ArrayList?
Thanks in advance.

Regarding default initial capacity of ArrayList, it would be 10. You can use ArrayList constructor to have it increased or decreased accroding to your use.
You can also use ensureCapacity method of Java ArrayList class.
Hope this helps...