added isPalindrome(), deallocated memory in removal methods