LeetCode 24 โ Swap Nodes in Pairs (Java + Pointer Diagram)
๐ง LeetCode 24 โ Swap Nodes in Pairs
In this problem, we're asked to swap every two adjacent nodes in a linked list. We're expected to not just change values, but swap the nodes.
โ
Problem Summary
Given a linked list, swap every two adjacent nodes ...
leetlog-by-chao.hashnode.dev2 min read