Mental Model
Find the longest part of a string that reads the same forwards and backwards by checking around each character.
Analogy: Imagine looking for the biggest mirror in a hallway where the reflection looks exactly the same from both ends.
s = "b a b a d" indexes: 0 1 2 3 4 Check centers ↑ at each letter and between letters for palindromes