We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b4fbba1 commit 6416c83Copy full SHA for 6416c83
palindrom.py
@@ -0,0 +1,8 @@
1
+def palindrom(s):
2
+ return s == s[::-1]
3
+
4
+word = input("Enter a word: ").lower()
5
+if palindrom(word):
6
+ print(word, "is a palindrom.")
7
+else:
8
+ print(word, "is not a palindrom")
0 commit comments