Like a linked list, but each node also points to the previous one — enabling traversal in both directions.
Like a linked list, but each node also points to the previous one — enabling traversal in both directions.
Time complexity: O(n). Space complexity: O(n).
Use the interactive visualizer above to run Doubly Linked List on your own input and watch every comparison, swap, and operation animate step by step — pause, scrub, or replay at any speed.