Skip to content

Latest commit

 

History

History
5 lines (5 loc) · 413 Bytes

File metadata and controls

5 lines (5 loc) · 413 Bytes

Problem 234 - Palindrome Linked List

The advanced challenge is implementing your algorithm with O(1) space complexity.
My S(1) algorithm is converting the iterative algorithm (stack) to recursive algorithm.
The recursive one transfers to memory overhead to function call stack though it seemingly cuts the extra space in the function.
So I solve this problem with a trivial S(n) = O(n) algorithm.