What are the Differences Between a Vector and an ArrayList in Java ?

An ArrayList is a newer class than a Vector. A Vector is considered a legacy class in Java. The differences are...

Synchronization : Vector is synchronized, but the ArrayList is not synchronized. So an ArrayList has faster operations than a Vector.

Data Growth : Internally both an ArrayList and Vector use an array to store data. When an ArrayList is almost full it increases its size by 50% of the array size. Whereas a Vector increases it by doubling the underlying array size.



You May Interest

What is the Use of Run Time Polymorphism in Java ?

What are the Different Scopes of a JSP Object ?

Why an Object Used as Key in HashMap Should Be Immutable in Java ...

How Will You Use Other Java Files of Your Application in JSP Code ...

What are the Main Benefits of Collections Framework in Java ?