← Microsoft questions

Pairwise Swap Linked List Nodes

Filed under Microsoft · Also reported at Oracle

Given a singly linked list, swap every two adjacent nodes and return the head of the modified list. You must solve the problem by actually swapping the nodes (changing pointers), not by merely…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Microsoft questions

Collected from public candidate posts and coding forums. Updated Nov 2026.