Question: 3. Write and test the following function def is palindrome (s): Determines if s is a palindrome. Ignores case, spaces, and punc tuation in s

 3. Write and test the following function def is palindrome (s):

3. Write and test the following function def is palindrome (s): Determines if s is a palindrome. Ignores case, spaces, and punc tuation in s Use: palindrome = 1S-palindrome (s) Parameters s a string (str) Returns: palindrome True if s is a palindrome, False othewise (boolean) Add this function to the PyDev module functions. py. Test it from q3.py Examples print (palindro)) lrue >> print (palindrome (' David')) False print (palindroOtto)) lrue > print (palindrome (' Able was I ere I saw Elba')) lrue print (palindrome ('A man, a plan, a canal, Panama!)) lrue

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!