ComputerScienceExpert

(11)

$18/per page/

About ComputerScienceExpert

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Applied Sciences,Calculus See all
Applied Sciences,Calculus,Chemistry,Computer Science,Environmental science,Information Systems,Science Hide all
Teaching Since: Apr 2017
Last Sign in: 103 Weeks Ago, 2 Days Ago
Questions Answered: 4870
Tutorials Posted: 4863

Education

  • MBA IT, Mater in Science and Technology
    Devry
    Jul-1996 - Jul-2000

Experience

  • Professor
    Devry University
    Mar-2010 - Oct-2016

Category > Programming Posted 11 May 2017 My Price 9.00

Write a C++ program that keeps track of an array of Person

Need help with this assignment

Write a C++ program that keeps track of an array of Person objects and handles basic commands.

The Person object contains the following fields:

  • FirstName { string }
  • LastName { string }

INSERT - inserts a Person into the array based on user input, sorts the array by last name, and prints out all of the entries in the array. (Format: INSERT - LastName, FirstName)

  • If a given Person already exists in the array, then the program will return an error message to the user.
  • If the user input does not follow the LastName, FirstName format, then the program will return an error message to the user.

Example:

Input - INSERT - Smith, John

Output

Doe, Jane

Smith, John

VIEW - prints out the current array. (Format: VIEW)

Example:

Input - VIEW                               

Output

Doe, Jane

Smith, John

DELETE - deletes a person from the array based on user input, sorts the array, and prints out all of the entries in the new array. (Format: DELETE - LastName, FirstName)

  • If the Person to be deleted from the array does not exist in the array, then the program will return an error message to the user.
  • If the user input does not follow the LastName, FirstName format, then the program will return an error message to the user.

Example:

Input - DELETE - Smith, John    

Output

Doe, Jane

Utilize functions, loops, and pointers where applicable, and remember to include error handling to let the user know if something went wrong during your program.

Answers

(11)
Status NEW Posted 11 May 2017 07:05 AM My Price 9.00

-----------

Not Rated(0)