Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Need to be answered correctly. You must: Comment and Format and Must make sure about indenting. If you don't follow these steps, it will be

Need to be answered correctly. You must: Comment and Format and Must make sure about indenting. If you don't follow these steps, it will be flagged for review. MUST BE IN JAVA FORMAT. IT IS A MUST. Please also check the output very carefully.

Exercise 2: Write a program that accepts a String as input from the keyboard and determines whether or not the String is a palindrome. Ignore whitespace and punctuation (space, tab, single quote, double quote, exclamation, comma, question mark, hyphen, semi-colon, colon, period). Ignore case as well. For example, all these inputs are palindromes:

A man, a plan, a canal, Panama.

Was it a car or a cat I saw?

If I had a hi-fi!!

Use the following template:

public class Palindrome{

public static void main(String[] args){

//code here

}

public static boolean isReverse (String line){

//code here

}

//add other methods if required

}

Need to be answered correctly. You must: Comment and Format and Must make sure about indenting. If you don't follow these steps, it will be flagged for review. MUST BE IN JAVA FORMAT. IT IS A MUST. Please also check the output very carefully.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts

Authors: David Kroenke, David Auer, Scott Vandenberg, Robert Yoder

8th Edition

013460153X, 978-0134601533

More Books

Students also viewed these Databases questions

Question

=+j Identify the challenges of training an international workforce.

Answered: 1 week ago