Data Structures Final Exam Review (Advantages/Disadvantages)
Heap
Advantage(s): -fast insertion -fast deletion -access to largest item Disadvantage(s): -slow access to other items
Graph
Advantage(s): -models real-world situations Disadvantage(s): -some algorithms are slow and complex
Queue
Advantage(s): -provides first-in, first-out access (FIFO) Disadvantage(s): -slow access to other items
Stack
Advantage(s): -provides last-in, first-out access (LIFO) Disadvantage(s): -slow access to other items
Linked list
Advantage(s): -quick insertion -quick deletion Disadvantage(s): -slow search
Array
Advantage(s): -quick insertion -very fast access if index known Disadvantage(s): -slow search -slow deletion -fixed size
Binary tree
Advantage(s): -quick search -quick insertion -quick deletion Disadvantage(s): -deletion algorithm
Ordered array
Advantage(s): -quicker search than unsorted array Disadvantage(s): -slow insertion -slow deletion -fixed size
Hash table
Advantage(s): -very fast access if key known -fast insertion Disadvantage(s): -slow deletion -access slow if key not known -inefficient memory usage