Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using C++, Add a function to both the Sale and Salesperson classes that returns the private salesperson ID number. Write a main()function that contains an

Using C++,

Add a function to both the Sale and Salesperson classes that returns the private salesperson ID number. Write a main()function that contains an array of five Salesperson objects and store appropriate data in it. Then, continue to prompt the user for Sale data until the user enters an appropriate sentinel value. For each Sale transaction entered, determine whether the salesperson's ID number is valid. Either display an error message, or use the friend display()function to display all the data.

Sample Run Enter salesperson ID or 0 to quit 103 Enter month of sale 2 Enter day 12 Enter year 2016 Enter amount of sale 1000 Sale #103 on 2/12/2016 for $1000 sold by #103 Woods Enter salesperson ID or 0 to quit 106 Enter month of sale 11 Enter day 25 Enter year 2016 Enter amount of sale 500 Sale #106 on 11/25/2016 for $500 sold by #106 Hansen Enter salesperson ID or 0 to quit 0 

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 Systems Design Implementation And Management

Authors: Peter Robb,Carlos Coronel

5th Edition

061906269X, 9780619062699

More Books

Students also viewed these Databases questions

Question

Explain the steps involved in training programmes.

Answered: 1 week ago

Question

What are the need and importance of training ?

Answered: 1 week ago