0
What is difference between arrayList and vector in java?
Java
3 Answers
+ 1
A Vector is similar with ArrayList, but it is synchronized. ArrayList is a better choice if your program is thread-safe.Vector and ArrayList require space as more elements are added. Vector each time doubles its array size, whileArrayList grow 50% of its size each time.
+ 1
Its performance on add and remove isbetter than Arraylist, but worse on get and set methods. Vector is similar withArrayList, but it is synchronized.
0
is ArrayList faster than vector?