0
0
HVHARIGOVIND VALSAKUMAR
PythonPalindrome
HGV Public CookbookFunction to check whether a string is a palindrome or not.
def palindrome(s):
s = "".join([character for character in s.lower() if character.isalnum()])
return s == s[::-1]
0
0
HVHARIGOVIND VALSAKUMAR
Function to check whether a string is a palindrome or not.
def palindrome(s):
s = "".join([character for character in s.lower() if character.isalnum()])
return s == s[::-1]