# Valid Palindrome

> LeetCode #125 — Valid Palindrome. Solve on LeetCode, then implement here if you want it in your drill queue.

https://leetcode.com/problems/valid-palindrome/

Canonical: https://learn.significanthobbies.com/curriculum/drills/lc-valid-palindrome

LeetCode #125 — Valid Palindrome. Solve on LeetCode, then implement here if you want it in your drill queue.

https://leetcode.com/problems/valid-palindrome/

## The mechanism

Two pointers replace a nested loop with a single pass by exploiting structure — usually a sorted array or a sequence with a monotonic property. The pointers move toward or away from each other based on a comparison, so each element is visited once.

## Expected evidence

Pass all LeetCode test cases for this problem.

## Hints

- Pattern hint: two pointers.
- Start with brute force, then optimize time/space.
- Write down invariants before coding.

## Sources and practice

- [NeetCode Roadmap](https://neetcode.io/roadmap)
- [Two Pointers — USACO Guide (Silver)](https://usaco.guide/silver/two-pointers)
- [cp-algorithms — Tortoise and Hare (linked list cycle detection)](https://cp-algorithms.com/others/tortoise_and_hare.html)
- [Study Two Pointers](https://learn.significanthobbies.com/curriculum/concepts/two-pointers)
- [Try the interactive drill](https://learn.significanthobbies.com/drills/lc-valid-palindrome)
- [All practice briefs](https://learn.significanthobbies.com/curriculum/drills/)
