Y
Hacker News
new
|
ask
|
show
|
jobs
by
paulddraper
3673 days ago
Or even more clearly
def is_palindrome(str): return str == str[::-1]
1 comments
eru
3673 days ago
According to the authors spec, you have to filter out spaces, normalize capitalisation etc.
So your solutions works after a preprocessing step.
link
paulddraper
3672 days ago
Correct, I wrote this based on the parent's desired answer.
link
So your solutions works after a preprocessing step.