Write a script file that will accomplish the following: a) Prompt the user to enter a...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Write a script file that will accomplish the following: a) Prompt the user to enter a word as a character array. b) First test that the user correctly entered a character array - if NOT, display this message to the user and end the program: You did not properly enter a word as a character array. Try again. c) If they did enter a valid input, create the reverse of the word using one or more loops. d) Test whether the word is a palindrome - meaning that the word spelled forwards and backwards is the same. e) Display a formatted message to the user, matching the format of the example below. Test that your code will work with the words 'racecar' and 'tomcat' The word racecar is a palindrome! The word tomcat is not a palindrome. Generate your flowchart and pseudocode for this problem Write a script file that will accomplish the following: a) Prompt the user to enter a word as a character array. b) First test that the user correctly entered a character array - if NOT, display this message to the user and end the program: You did not properly enter a word as a character array. Try again. c) If they did enter a valid input, create the reverse of the word using one or more loops. d) Test whether the word is a palindrome - meaning that the word spelled forwards and backwards is the same. e) Display a formatted message to the user, matching the format of the example below. Test that your code will work with the words 'racecar' and 'tomcat' The word racecar is a palindrome! The word tomcat is not a palindrome. Generate your flowchart and pseudocode for this problem
Expert Answer:
Related Book For
Systems analysis and design
ISBN: 978-0136089162
8th Edition
Authors: kenneth e. kendall, julie e. kendall
Posted Date:
Students also viewed these programming questions
-
You are required to write a Python program that will manage character (heroes and villain) information. Character (hero and villain) information will be stored in a text file that will be read in...
-
This assignment reviews object-oriented programming concepts such as classes, methods, constructors, accessor methods, and access modifiers. It makes use of an array of objects as a class data...
-
You have this information r*=2.5%, inflation premium =3%, default risk premium=3.5%, liquidity premium =2% and maturity risk premium =1.5%.What is the treasury bill rate?
-
Let's look at Dick's Sporting Goods (Dick's) some more. Think about Dick's. How much cash does Dick's have? What are the sources and uses of Dick's cash? Return to Dick's Annual Report and look at...
-
Five percent of the many cars produced at a plant are defective. Ten cars made at the plant are sent to a dealership. Let X be the number of defective cars in the shipment. a. Under what conditions...
-
Describe the duties of healthcare organizations, the CEO, and medical staff.
-
Does It Matter Where You Sell? Some marketers feel that the image of the particular channel in which they sell their products does not matterall that matters is that the right customers shop there...
-
Assume the appropriate discount rate for the following cash flows is 9.4 percent. Year 1 234 Cash Flow $1,700 1,600 1,300 1,100 What is the present value of the cash flows?
-
Peta is married, filing joint with two other dependents, is paid $17.25 per hour, and receives commission on sales. No commission is paid out until sales exceed $60,000. Once the minimum sales have...
-
How much must ultimately be saved in an account to assure the ability to withdraws $10,000 per month for the next 10 years if the investments earns 9% annually on average?
-
A pressure cooker contains 0.5 m 3 water and water vapor mixture at 300C. Calculate the mass of each if their volumes are equal.
-
A particle carrying charge \(q_{\mathrm{p}}=+10 \mathrm{nC}\) is located at \(y_{\mathrm{p}}=0.030 \mathrm{~m}\) on the \(y\) axis of an \(x y\) coordinate system. A nonconducting rod of length...
-
Mr. G.C. Gupta, the erstwhile Marketing Director of Hindustan Industrial Corporation Ltd., has recently taken over as the Managing Director of the company. He is an engineer by qualification and a...
-
A particle carrying charge \(+q\) is placed at the center of a thick-walled conducting shell that has inner radius \(R\) and outer radius \(2 R\) and carries charge \(-4 q\). A thinwalled conducting...
-
Classify each of the following costs as a direct cost or an indirect cost, assuming that the cost object is the Juniors Department (clothing and accessories for teenage and young women) in the Stow...
-
Multicultural teams can be extremely effective when managed properly. See Table 5-1. Using a real life example (or be creative), please explain 2 incidents that demonstrate how the disadvantages of...
-
Cassandra Casey operates the Futuristic Antique Store. She maintains subsidiary ledgers for accounts payable and accounts receivable. She presents you with the following information for October 2019:...
-
Nick, a celebrity chef/restaurant owner from Williamsburg, New York, wants to be able to receive clear feedback on the systems used to manage his many show place restaurants. Design a display that...
-
Give two instances that indicate that display output is the best solution for the choice of output technology.
-
In what four categories does the FOLKLORE documentation method collect information?
-
Plaintiff applied for a job at Neiman Marcuss Oak Brook, Illinois, store as an entry-level dress collections sales associate. Ohle was interviewed and was informed that she should expect an offer for...
-
Plaintiff Deborah Ehling was hired by Monmouth-Ocean Hospital Service Corp. (MONOC) in 2004 as a registered nurse and paramedic. Plaintiffs claims in this case arise out of an incident involving her...
-
Reynaldo Delgado died following an explosion at a smelting plant in Deming, New Mexico, after a supervisor ordered him to perform a task that, according to Delgados widow, was virtually certain to...
Study smarter with the SolutionInn App