链表
Data Structures & Algorithms · 8 notes
- Print Linked List from Tail to Headhistorical
Record recursive and stack-based methods for outputting a linked list from tail to head.
- Reverse Linked Listhistorical
Record stack-based and three-pointer implementations for reversing a singly linked list.
- Merge Two Sorted Linked Listshistorical
Record iterative and recursive implementations for merging two sorted linked lists.
- K-th Node from the End of a Linked Listhistorical
Record array, length-conversion, and fast-slow-pointer methods for finding the k-th node from the end.
- Copy Complex Linked Listhistorical
Record the method of copying a complex linked list by inserting copied nodes after the original nodes.
- Entry Node of a Loop in a Linked Listhistorical
Record set-based and fast/slow-pointer methods for finding the entry node of a linked-list cycle.
- First Common Node of Two Linked Listshistorical
Record a two-pointer method that uses the length difference to find the first common node of two linked lists.
- Delete Duplicate Nodes in a Linked Listhistorical
Record counting- and set-based methods for deleting all duplicate nodes from a sorted linked list.