Question: Write a class called Palindrome that implements the provided the PalindromeInterface. It only requires a single method: isPalindrome which takes a String as a parameter.

Write a class called Palindrome that implements the provided the PalindromeInterface. It only requires a single method: isPalindrome which takes a String as a parameter. The method should make use of an instance of the MyStack class to verify whether the the String is a palindrome. Your method should ignore all spaces and be case insensitive. The method returns true if it is a palindrome, false if not.

We will test your method on our own input, but it would be a good idea to create your own tester class that instantiates the Palindrome class and checks it against a few things that are (and a few things that are not) palindromes to ensure that its working correctly.

PalindromeInterface.java:

public interface PalindromeInterface {

public boolean isPalindrome(String x);

}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!