Whether a string is a palindrome or not

Assignment Help Programming Languages
Reference no: EM13948216

Write a program that reads in strings of characters and determines if each string is a palindrome. Each string appears on a separate input line. Echo-print each string, followed by " Is a palindrome" if the string is a palindrome or "Is not a palindrome" if the stringis not a palindrome. For example, given the input string Able was, I ere I saw Elba. The program should print "Is a palindrome." In detemining whether a string is a palindrome, consider uppercase and lower case letters to be the same and ignore punctuation characters and spares. The input file that you will be reading palindromes from is called "pals.txt". Look for methods like replace (), to lowerCase, to UpperCase,..etc. Write the output ( the string and if is a palindrome) to a file called "palsout.txt". Each line of text in the file pals.txt will contain a palindrome to test for. You can only use the BufferedReader class and not the Scanner class. Please examine the attachment, this is as far as I got, however I am able to compile but when executing I get and error. Please select palindrome files to save in the pals.txt file.

Attachment:- Palindrome Test.doc

Reference no: EM13948216

Questions Cloud

Screw dislocations of opposite sign : 1. Is it possible for two screw dislocations of opposite sign to annihilate each other? Explain your answer. 2. For each of edge, screw, and mixed dislocations, cite the relationship between the direction of the applied shear stress and the directi..
Reid found qualified replacement property which is acquired : Reid found qualified replacement property which is acquired six months later for $390,000. What is the amount of reid's realized gain and recognized gain?
Write an applet file that prompts the user for an id number : Catch the Exception and then display an appropriate message. Save the program as BadIDAndAge.java
Ignoring any minor variations in tense or mood : Part B: Construct an original example, in English in standard form, of each of the following. If it is not possible to do so, say why. Be sure to use premises and conclusions the truth value of which it is reasonable for you to believe that your mark..
Whether a string is a palindrome or not : Please examine the attachment, this is as far as I got, however I am able to compile but when executing I get and error. Please select palindrome files to save in the pals.txt file.
Evaluate the top five challenges of conducting quantitative : Evaluate the top five challenges of conducting quantitative and qualitative research and stipulate to strategies to overcome those challenges from the literature on research design theory and practice.
Can you provide an intuitive explanation : Compare the firms' profits under quantity competition and price competition. Can you provide an intuitive explanation for why price competition is more intense (i.e. leads to lower equilibrium profits)?
What might be the challenges faced by your teams : Where might the formation of a team in terms of cellular production benefit your company and/or what "teams" are effective in your company at present? What might be the challenges faced by your teams
Effect on the organizational structure : Assignment: Kudler Fine Foods is in the process of developing a new frequent shopper program. Details of this program are described in the Service Request SR-kf-013 and on the Sales & Marketing page of the Kudler Fine Foods intranet website.

Reviews

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create an application to run in the amazon ec2 service

In this project you will create an application to run in the Amazon EC2 service and you will also create a client that can run on local machine and access your application.

  Explain the process to develop a web page locally

Explain the process to develop a Web page locally

  Write functions

These 14 questions covers java class, Array, link list , generic class.

  Programming assignment

If the user wants to read the input from a file, then the output will also go into a different file . If the user wants to read the input interactively, then the output will go to the screen .

  Write a prolog program using swi proglog

Write a Prolog program using swi proglog

  Create a custom application using eclipse

Create a custom Application Using Eclipse Android Development

  Create a application using the mvc architecture

create a application using the MVC architecture. No scripting elements are allowed in JSP pages.

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Design a program that models the worms behavior

Design a program that models the worm's behavior.

  Writing a class

Build a class for a type called Fraction

  Design a program that assigns seats on an airplane

Write a program that allows an instructor to keep a grade book and also design and implement a program that assigns seats on an airplane.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd