IBM interview question

Write a method that determines if a string is a palindrome. Know OOP concepts such as inheritance.