method to define palindrome added