Reference no: EM131138874
In this programming assignment, you'll identify the number of potential customers for a business. The starter program outputs the number of potential customers in a userentered age range given a file with people's data.
1. Move the class Person to the separate files: person.h and person.cpp. Make sure you can still compile with separate files.
2. During file reading, the program isn't storing the gender or yearly income of the people. Instead, the default values are being printed. Fix the program to correctly set the data read from file.
The regions of the code that need to be fixed are marked with:
"FIXME Also set gender and yearly income"
3. Allow the user to select the potential customer's gender: "male", "female", or "any". The program should now output only potential customers with the userspecified gender and age. Update the GetUserInput function to prompt the user and store the user's gender selection. Also, create a function GetPeopleWithSpecificGender that returns only people with the userspecified gender.
Debugging suggestion: Use a function to print main's vector of Persons so that you can see who is in the vector after each function call. This technique may help debug the newly created function GetPeopleWithSpecificGender.
4. In addition to age and gender, allow the user to select the lower and upper range of a customer's yearly income.
Update the GetUserInput function to prompt the user and store the user's specified range. Also, create a function GetPeopleInIncomeRange that returns only people with the userspecified yearly income.
Attachment:- Assignment.rar
How disney diversifies with acquisitions
: Discuss why Disney’s vision and mission make the firm one of the most admired firms and how Disney diversifies with acquisitions, such as Lucasfilm.
|
Identify an acute and non-acute health care facility
: Identify an acute care facility and a non-acute health care facility in your area. Arrange to speak to the health information management professional at each facility and discuss the challenges they feel they face in collecting data, the type of d..
|
The public sphere-the social sphere-the tribal sphere
: In Advertising's New Medium: Human Experience by J.F. Rayport, he discusses the four spheres of human experience (The Public Sphere, The Social Sphere, The Tribal Sphere, and the Psychological Sphere) as a way of better structuring advertising to rea..
|
What is the price per share of the company stock
: Ward Corp. is expected to have an EBIT of $2,000,000 next year. Depreciation, the increase in net working capital, and capital spending are expected to be $167,000, $89,000, and $117,000, respectively. All are expected to grow at 16 percent per year ..
|
Identify the number of potential customers for a business
: In this programming assignment, you'll identify the number of potential customers for a business. The starter program outputs the number of potential customers in a userentered age range given a file with people's data
|
Acting within the course and scope of his employment
: Bob's Painting Service hired 3 temporary workers through Deb's Temps. Bob didn't ask if back ground checks had been done on the employees. Deb did not check the criminal records for the workers hired by Bob. Bob may be liable because he did not make ..
|
Determine the expected rate of return on phoenix stock
: Assuming that Phoenix is not expected to pay any dividends during the coming year, determine the expected rate of return on Phoenix Stock.
|
Evaluation of applicants attitudes
: If your boss was not sure if it would be worth the investment to change the company's hiring practices to include an evaluation of applicants' attitudes, what would you tell him or her?
|
Determine the equation for distribution of shear strength
: (Hint: Try a circular failure surface, determine the equation for the distribution of shear strength with depth, and integrate the shear strength over the radius to find the shear force.)
|