Home > Software > Java > Core-Java
Interview Questions   Tutorials   Discussions   Programs   

Core-Java - What is the difference between Array List and Vector?




302
views
asked marvit August 16, 2014 10:37 AM  

What is the difference between Array List and Vector?


           

1 Answers



 
answered By bhjahnavi   0  
ArrayList  Vs Vector
1. ArrayList object is not synchronized by default, whereas vector object is synchronized by default.
2. In case of a single thread , using ArrayList is faster than the vector,in case of multiple threads, using vector is advisable .with a single thread,vector becomes slow.
3. ArrayList increases its size every time by 50 percent (half), where as vector increases its size every time by doubling it.
flag   
   add comment

Your answer

Join with account you already have

FF

Preview


Ready to start your tutorial with us? That's great! Send us an email and we will get back to you as soon as possible!

Alert