Linked List

noun

say it: “LINKT LIST” /lɪŋkt lɪst/

A chain of nodes, each holding an item and a reference to the next node.

What is a linked list?

A linked list is a chain of nodes, each holding one item and a reference to the next node, like train cars coupled together. The first node is the head, and the last node's next reference is empty. Adding or removing at the front is O(1), but reaching a position means walking from the head, O(n).

In a sentence

  • “The music app keeps 'up next' in a linked list, so adding a song at the front never moves the others.”

Level: Apprentice · More Data Structures terms at this level

Updated