import java.util.Scanner; public class Palindromer { @SuppressWarnings("resource") public static void main(String[] args) { Scanner input = new Scanner(System.in); while (true) { System.out.println("Enter string to check for Palindrome"); String pal = input.nextLine(); pal = pal.toLowerCase().replace(" ", ""); boolean odd = pal.length()%2 == 1; // really want char in stack, but it is primitive type // so use Character similar to int/Integer AStack aSStr = new AStack<>(); for (int i=0; i