Prabhat Ranjan wrote:1)
this statment is wrong. The initial size for ArrayList and Vector is 10.
2) ArrayList increases its capacity by half approximately whenever its capacity reaches maximum (10) is wrong
but Vector increases its capacity by double whenever its capacity reaches maximum. thi is correct.
please comments !
You ought to look in the Sun/Oracle documentation.Prabhat Ranjan wrote:. . . please comments !
Prabhat Ranjan wrote:one point i want to highlight here ArrayList Capacity is 0 initially as ArrayList doesn't have method like capacity (but Vector has).
Constructs an empty list with an initial capacity of ten.
Santosh Kumar Nayak wrote:ArrayList increases its storage by using the below formula:-
OldCapacity*3/2+1
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here