Working on an isPalindrome function