Identify the number of potential customers for a business

Assignment Help C/C++ Programming
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 user­entered 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 user­specified 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 user­specified 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 user­specified yearly income.

Attachment:- Assignment.rar

Reference no: EM131138874

Questions Cloud

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 user­entered 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.)

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Display the largest and smallest numbers entered

Design a java program with a loop that lets the user enter a series of numbers - After all the numbers have been entered, the program should display the largest and smallest numbers entered.

  Which of the following correctly invokes the function f

which of the following correctly invokes the function F, assuming N is an integer variable?

  Implement the readlog function

Implement the readLog function below, which is to (1) read the file, (2) populate a vector for each column, and (3) return the number of lines found.

  Write an iterative version and a recursive version

Write a main program that illustrates the work of your functions. E.g., if a[ ]={1,2,3,3,4,5} then 3 occurs 2 times and 7 occurs 0 times.

  Allocate array of n doubles and assign the resulting pointer

The variable dp is to refer to an array of double. Assuming the integer variable n has been assigned a value, declare dp appropriately, allocate an array of n doubles and assign the resulting pointer to dp.

  Use selection sort to sort a[48] into increasing order

Use selection sort to sort A[48] into increasing order, and then print out the sorted list in four rows. There may be duplicates, but that's OK. (65 and 53 appear twice.) Duplicates will appear next to each other in the sorted list.

  The program write a program to analyze all integers

Part 1: The Program Write a program to analyze all integers contained in two text files. Both text data input files will contain an unknown number of integers (in the range 1 - 999), separated by whitespace. There may be duplicate integers in the fil..

  What is a cell reference

What is a cell reference (also called a cell address) and what is the significance of being able to use them in spreadsheet formulas?

  Design a phonecall class that holds a phone number

Design a PhoneCall class that holds a phone number to which a call is placed, the length of the call in minutes, and the rate charged per minute. Overload extraction and insertion operators for the class.

  Define the class bankaccount

Define the class bankAccount to implement the basic properties of a bank account. An object of this class should store the following data: Account holder's name (string), account number (int), account type (string, checking/saving), balance (double),..

  Write a function that collects integers from the user

Write a function that collects integers from the user until a 0 is encountered and returns them in a list in the order they were input (ML only).

  To use a sentinel loop so once the value of -99 i

modify this program to use a sentinal loop so once the value of -99 is entered after getting the pay and hours the program should end.

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