206. Reverse Linked List

by

Duct Tape Programmer


Question

Reverse a singly linked list.

Quick Hints

Solution

Iterative:
Recursive:

Time complexity

O (n)

Space complexity

O(1) for iterative O(n) for recursive

Notes

comments powered by Disqus