Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
Count the number of pairs of characters that should be equal if s were a palindrome, but are not equal.
If the number of pairs is 0, then s is already palindrome. You can pick any pair of characters and change them both to a different character and s will stay a palindrome.