def is_palindrome(input): input = input.lower() return input[::-1] == input print("\x1b[2J") print("Father") print(is_palindrome("Father")) print "\n" print("Dad") print(is_palindrome("Dad")) print "\n"
Output
Lab Core | The Lab of MrNetTek
A blog about IT, technical solutions, and code.