Summary

 [Previous Chapter]  [Previous Page]  [Contents]


Data StructureAccess DisciplineSize

ArraysRandom Accessfixed
VectorRandom Accessresizes automatically
StackLIFOjava.util.Stack has no size limits as it is based on java.util.Vector
QueueFIFOdepends on the implementation

*Native arrays are more efficient than instances of Vector.
 
*Stacks and queues can be very efficiently implemented even if they have no size limits (on base of LinkedList).
 
*Vectors are flexible but implicit resize operations and removals can be costly (linear complexity as compared to constant complexity in case of linked lists).
 

 [Previous Chapter]  [Previous Page]  [Contents]
Copyright © 2001, 2002 Andreas Borchert, converted to HTML on February 11, 2002