Problem 3294 · Medium

Convert Doubly Linked List to Array II

From any node, climb prev pointers to the head first, then walk next pointers to read the list in order.

Open the interactive visualisation