Palindrome NumberEasy

math two pointers digit manipulation

Return true if an integer x reads the same forwards and backwards. Two approaches — a string two-pointer check, and a no-string trick that reverses only the second half.

Press play to watch the algorithm run.
Metrics
Legend
How it works
0 / 0