Diff between ArrayList and Vector?



Share on Google+Share on Google+

Dilvin Riyo
Diff between ArrayList and Vector?
1 Answer(s)      6 years and 3 months ago
Posted in : Java Beginners

What's The Difference between ArrayList and Vector Classes and Can you give me a simple Program for set and List Interface . . .

View Answers

July 25, 2011 at 4:52 PM

Difference between ArrayList and Vector:

1)Vectors are synchronized while ArrayList are not.

2)When an element is inserted into ArrayList or Vector then vector doubles its size of array while ArrayList increases upto 50 percent.

Example of Set Interface

Example of List Interface