In the PaindromeStack class, write Java code for the following question by adding code at the ADD YOUR CODE HERE Write a
Posted: Tue Jul 12, 2022 8:16 am
question by adding code at the ADD YOUR CODE HERE Write a Java program that uses ArrayStack (array stack from Chapter 3) to determine whether an input string is a palindrome. * A paindrome is a string of characters (a word, phrase, or sentence) that is the same regardless of whether you read it forward or backward. T *Here are two sample runs: Enter a string abcdcba The input string is a palindrome. T " Enter a string: abcdefg The input string is not a palindrome. import java.util.Scanner, public class PalindromeStack ( public static void main(String[] args) { System.out.print("Enter a string: "); Scanner input = new Scanner(System.in);
In the PaindromeStack class, write Java code for the following