Part 3
Linked Lists
23lessons2 h 11 min0done on this device
A linked list is a structure whose elements do not sit side by side in memory; each element carries the address of the next. That is why inserting at the front takes O(1), but you cannot jump to an element by its index.
The part opens with an introduction and then splits into three subtopics. First the singly linked list, then the doubly linked list where each node knows both neighbours, and finally the circular list where the last node points back to the start. Every operation is its own lesson.
- 3.1.1What is a singly linked list?5 min
- 3.1.2Creating a singly linked list6 min
- 3.1.3Traversal5 min
- 3.1.4Inserting at the end5 min
- 3.1.5Inserting at a position7 min
- 3.1.6Inserting at the head4 min
- 3.1.7Deleting from the end6 min
- 3.1.8Deleting from the head4 min
- 3.1.9Deleting from the middle6 min
- 3.1.10Searching for a value4 min
- 3.1.11Reversing a linked list (iterative)7 min
- 3.1.12Reversing a linked list (recursive)8 min