Question about java ArrayList

Soldato
Joined
1 Mar 2003
Posts
5,508
Location
Cotham, Bristol
Ok so you setup a new ArrayList like so

ArrayList list = new ArrayList(20);

You then add 10 items to the list, leaving it half full.

If I then do the following

listSize = list.size();

What is listSize? Is it 10 or 20?
 
Back
Top Bottom