Loading...
Loading...
Loading...
A word is a palindrome when it reads the same forwards and backwards. Capital letters do not matter.
Read one word and print Yes if it is a palindrome, otherwise No.
Yes or No.Example 1
Input
Level
Output
Yes
Lower case it: level. Reversed: level.
Example 2
Input
Mentor
Output
No
Try the problem first. Open one hint at a time.
Change the case first so L and l match.
Compare the word with its reversed slice.
Write your Python code, run it on the examples and submit it to hidden tests.
Solve in the editor