Linked List

Definition

A linked list is a data structure that (typically) uses dynamically allocated elements called node to implement a sequence. Each node has a value field and a link field which allows access to the next item of the list.

Figure

Doubly Linked List

Figure

Operations for Singly Linked Lists

Operations are similar for doubly linked lists. The way I like to remember these is just using these diagrams, and visualizing how the arrows move around.

Figure

Sorted Linked List vs Sorted Dynamic Array

See Computer Science/Programming/Arrays.