34
u/sugarsnuff Apr 14 '23
This took me more than a second to think through
I guess when we think of a palindrome, we think of a literal symmetrical reflection
37
8
8
7
12
9
1
6
u/cainhurstcat Apr 14 '23
May someone could please help me understand this?
13
u/maneinblack Apr 14 '23
The visible trick of ( makes us think that in palindrome, the expected result is ). You don’t reverse the actual character, just the ordering.
( 0 ( is valid but (0) is not.
6
4
6
2
2
2
1
103
u/BetterSnek Apr 14 '23
It's less confusing if you replace it with characters that don't look like they stack inside of each other.
ABBA ABAB