palindrome.py 201 B

12345
  1. text = input('Enter any text or number: ')
  2. if text[::-1] == text:
  3. print('The text you entered is a palindrome')
  4. elif text[::-1] != text:
  5. print('The text you entered is not a palindrome.')