Question: A palindrome is a string that is the same backward as it is forward. For example,tot and otto are rather short palindromes. Write a program
A palindrome is a string that is the same backward as it is forward. For example,“tot” and “otto” are rather short palindromes. Write a program that lets a user enter a string and that passes to a bool function a reference to the string.The function should return true if the string is a palindrome and false otherwise. At this point, don’t worry about complications such as capitalization, spaces, and punctuation. That is, this simple version should reject “Otto” and “Madam, I’m Adam.” Feel free to scan the list of string methods in Appendix F for methods to simplify the task.
Step by Step Solution
3.34 Rating (169 Votes )
There are 3 Steps involved in it
ANSWER include include using namespace std bool isPalindromestring str ... View full answer
Get step-by-step solutions from verified subject matter experts
