Menu

[solved] – Question 77719

Write a recursive function

bool is_palindrome(string str)

that returns true if str is a palindrome, that is, a word that is the same when reversed. Examples of palindrome are “deed”, “rotor”, or “aibohphobia”. Hint: A word is a palindrome if the first and last letters match and the remainder is also a palindrome.

Expert Answer


OR


Leave a Reply

Your email address will not be published. Required fields are marked *