Write down a program that reads a person''s name

Assignment Help Computer Engineering
Reference no: EM1331961

Write a program that reads a person's name in the following format: first name, then middle name or initial, and then last name. The program then outputs the name in the following format:

Last_Name, First_Name Middle_Initial.

For example, the input
Mary Average User

should produce the output:
User, Mary A.

The input
Mary A. User

should also produce the output:
User, Mary A.

Your program should work the same and place a period after the middle initial even if the input did not contain a period. Your program should allow for users who give no middle name or middle initial. In that case, the output, of course, contains no middle name or initial. For example, the input
Mary User

should produce the output
User, Mary

If you are using C strings, assume that each name is at most 20 characters long. Alternatively, use the class string. Hint: You may want to use three string variables rather than one large string variable for the input. You may find it easier to not use getline.

Reference no: EM1331961

Questions Cloud

Write the thoughts according to you : All doctor offices have not become 100 percent computerized yet. You can still see good % of offices use manual patient record files indexed by the first letter of patients' last names.
Different forms of corruption : How does corruption come about within an organization? Explain in detail. What conditions must exist, or what factors allow corruption to seep into public organizations? Explain in detail.
Explain business systems and non-metric variables : Explain business systems and non-metric variables
How to an edited version of the same text to another file : create a program that reads text from one file and writes an edited version of the same text to another file.
Write down a program that reads a person''s name : Write down a program that reads a person's name.
Explain what are the similarities among brick and mortar : Explain what are the similarities among brick and mortar
Examining cultural and ethnic differences of countires : Examine the cultural and ethnic differences of the two selected countries and determining the appropriate negotiation tactic that would be most effective in reaching the objective.
U.s. border security : Prepare a comprehensive plan for U.S. border security. The plan will include concepts such as border security, immigration issues, economic impact and future political ramifications.
Preserve uppercase letters for the first word of sentence : create a program that can be used to train the user to use less sexist language by suggesting alternative versions of sentences given by the user.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Troubleshooting the software

AV software has eliminated the malware from highly infected system. After the first reboot, an error message is displayed that consists of the reference to strange DLL file that is missing.

  Words might appear multiple times in the entered text

write down a program that allows the user to enter a line of text. I then need to use the stringTokenizer to break the input into words. I have to Put these words into a link list and then print them out in alphabetical order.

  Advantages and disadvantages to using cots

What are the advantages and disadvantages to using COTS (Commercial Off-the-Shelf) software versus writing your own software within a company environment? Give some examples of problems you have had.

  Define the syntax of programming languages

BNF is used extensively in the computing field to describe the syntax of programming languages. Please provide an example of where and how BNF may be used to solve real-world problem.

  Multiplexer and decoder

A bus organized the CPU has 32 registers with 16 bits in each, an ALU and a destination decoder. Specify how many multiplexers are there within the bus, and specify the size of each multiplexer?

  Program to calculate the weight of students

We have run regression analysis along with the resulting estimated regression equation as follows:” the estimated weight equals (-180 pounds) plus (5 pounds times the height in inches).” Write down the program to calculate the weight of students.

  Explain how to compile and run a standalone java application

Write a simple Java program that incorporates as a minimum three best practices for making your code readable and understandable by yourself and others.

  Create an application that generates a quiz

Create an application that generates a quiz

  The cpu of a personal computer''s hardware

Discuss in detail \CPU of a personal computer's hardware, and define how the characteristics of that aspect affect overall computer performance.

  Related to the polygon

Assume n=3 and P has positive area. Explain how to determine efficiently whether exactly one of the point’s q and r falls inside of P. Analyze how much time is utilized.

  Determining occurance as incident or disaster

Categorize the following occurrences as an incident or disaster. If an occurrence is a disaster, find whether or not business continuity plans would be called into play.

  Define the criteria for go vs. nogo

The final phase of a project is the close-out also known as the post mortem. When the project reaches this phase, the project has been successfully delivered and all tasks are complete. What do you think detail tasks in this phase must be.

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