what is difference between vector and arraylist?.

Answers were Sorted based on User's Feedback



what is difference between vector and arraylist?. ..

Answer / guest

vector is synchronized . collection object and variable
slow acess. muntable
array list is never snchronized. collection variable fast
acess

Is This Answer Correct ?    16 Yes 1 No

what is difference between vector and arraylist?. ..

Answer / srinivas

Vector is synchronized and compare to array list this slow
access, by defaulst the vector is 10,this is legacy class
Where as arraylist is unsynchronized and fast random
access,in arraylist there is no default size automatically
it is growable once the object is created it will be
allocated,this is advanced class.

Is This Answer Correct ?    10 Yes 2 No

what is difference between vector and arraylist?. ..

Answer / srinu

vector:-
1)Vector is a synchronized.
2)These are Thread safe.
3)performance slow
4)it implements
serializible,list,collection,iterable,Randomaccess,clonable
interfaces.
5)vector is optimum storage management.

Arraylist:-
1)ArrayList is not synchronized.
2)these are not safe.
3)performance is high.
4)it implements
serializible,list,collection,iterable,Randomaccess,clonable
interfaces.
5)ArrayList is not a optimum storage management

Is This Answer Correct ?    5 Yes 0 No

what is difference between vector and arraylist?. ..

Answer / arjun kumar

If we want to arrange a collection of objects into an other object then we will use either ArrayList or Vector. When we use these classes all the objects that are placed in it will be stored sequentially one after the other.

ArrayList : If we want to store same type of objects then we will use ArrayList class.

Vector : If we want to store different type of objects then we will use Vector class.

Is This Answer Correct ?    1 Yes 3 No

Post New Answer

More Java J2EE AllOther Interview Questions

What are the queues in the java collection framework? : java collections

0 Answers  


Write a postfix expression to (a*(b+c/d)*d-e)

4 Answers   Adobe,


whats the relation ship between LDAP and JNDI?

1 Answers  


Explain the OOPS concept in Realtime Scenarion ? Take example as CAR. Please explain indetail ?

0 Answers   Cap Gemini,


who should use JNDI?

1 Answers  






What is difference between Application Server and Web Server?

1 Answers   Logica CMG, SCS,


Q1. A. Write note on "The class path Environment Variable". B. Which are different kinds of source code? Q2. A. How to create an interface? B. Why convert an applet to an application? Q3. A. How to use Media tracker Class. B. How to use string tokenizer class. Q4. A. Explain the overview of UDP messaging. B. Difference between SQL Exception class and SQL Warning class. Q5. A. How to create com object in Java? B. Write short notes on "The properties class" Q6. A. When object is created and destroyed? B. Explain the JDB in depth & command line. C. Write short notes on Web Sites.

1 Answers  


what is difference between struts1.2 and struts2.0

1 Answers  


what is jndi?

2 Answers  


Is it possible to create Userdefined Unchecked Exception also?If Yes, give an example?

1 Answers   HCL,


Which interface does java.util.hashtable implement?

0 Answers  


"Sun Certified Java Programmer" This is one String , we need to print SCJP, write the java code dynamically? pls reply this questions

6 Answers   Photon,


Categories