RE: What is the difference between ArrayList and Vecto...
In Vector, there is a constructor for specifing initial capacity and incremental capacity. Where as in ArrayList there no constructor for specifing incremental capacity.
Vector, it defaults to doubling the size of an array. In ArrayList, it icreases its array size by 50%.
RE: What is the difference between ArrayList and Vecto...
-Arraylist has no default size while vector has a default size of 10. -Arraylist don't define any increment size while vector does. -arraylist can be seen directly without any iterator while vector requires an iterator to display all it's content. (not very sure).
RE: What is the difference between ArrayList and Vecto...
Request tll all those who post reply..please only post replies if u know correct..or if u r not sure..alteast mention not sure...why to say something wrong that creates problem for others..this is very good site...pls let us maintain it correctness...
Vector and Arraylist both has initial capacity and it is 10
Vector is synchronized and Arraylist is not
Vector has option to set incremental capacity Arraylist does not have.
There is a difference b/w thw way both grows but I am not sure exactly what is the difference in terms of growth rate.
RE: What is the difference between ArrayList and Vecto...
1. In vector the data is retrieved using the elementAt() method 2. In ArrayList, it is done using the get() method. 3. ArrayList has no default size while vector has a default size of 10. 4. ArrayList doesn’t have a constructor for specifying the incremental capacity, where as Vector has a constructor to specify the initial capacity and incremental capacity.
RE: What is the difference between ArrayList and Vector otherthan arrayList is not synchronised but Vector is?
It is similar to ArrayList, but with two differences: Vector is synchronized, and it contains many legacy methods that are not part of the collections framework.