finished simple palindrome class.