check if string can be palindrome exercise