1 create a class named rates that has the following data members 1 income limit use 5346475

1. Create a class named rates that has the following data members:
1. Income limit; use read-only accessor.
2. Low tax rate; use read-only accessor.
3. High tax rate; use read-only accessor.
4. A class constructor that assigns default values of limit=30000, low rate = .15 and high rate = .28.
5. A class constructor that takes three parameters to assign input values for limit, low rate and high rate.
6. A CalculateTax method that takes an income parameter and computes the tax as follows:
1. If income is less than the limit then return the tax as income times low rate.
2. If income is greater than or equal to the limit then return the tax as income times high rate.
2. Create a class named Taxpayer that has the following data members:
1. Social Security number (use type string, no dashes between groups). Use get and set accessors.
2. Yearly gross income. Use get and set accessors.
3. Tax owed. Use read-only accessor.
3. The Taxpayer class should be set up so that its objects are comparable to each other based on tax owed.
4. The tax should be calculated whenever the income is set.
5. The Taxpayer class should have a getRates class method that has the following:
1. Local method data members for income limit, low rate and high rate.
2. Prompt the user to enter a selection for either default settings or user input of settings.
3. If the user selects default the default values you will instantiate a rates object using the default constructor and set the Taxpayer class data member for tax equal to the value returned from calling the rates object CalculateTax method.
4. If the user selects to enter the rates data then prompt the user to enter values for income limit, low rate and high rate, instantiate a rates object using the three-argument constructor passing those three entries as the constructor arguments and set the Taxpayer class data member for tax equal to the value returned from calling the rates object CalculateTax method.
6. In Main:
1. instantiate an array of five (5) Taxpayer objects.
2. Implement a for-loop that will prompt the user to enter the Social Security Number and gross income.
3. Implement a for-loop that will display each object as formatted taxpayer SSN, income and calculated tax.
4. Implement a for-loop that will sort the five objects in order by the amount of tax owed and then display each object as formatted taxpayer SSN, income and calculated tax.
7. Internal documentation.

Possible output for the program would look like this:

Enter Social Security Number for taxpayer 1 555555555
Enter gross income for taxpayer 1 35000
Do you want default values (enter D) or enter your own (enter O)? d
Enter Social Security Number for taxpayer 2 111111111
Enter gross income for taxpayer 2 80000
Do you want default values (enter D) or enter your own (enter O)? o
Enter the dollar limit 50000
Enter the low rate .15
Enter the high rate .25
Enter Social Security Number for taxpayer 3 333333333
Enter gross income for taxpayer 3 45000
Do you want default values (enter D) or enter your own (enter O)? d
Enter Social Security Number for taxpayer 4 444444444
Enter gross income for taxpayer 4 65000
Do you want default values (enter D) or enter your own (enter O)? o
Enter the dollar limit 70000
Enter the low rate .10
Enter the high rate .20
Enter Social Security Number for taxpayer 5 222222222
Enter gross income for taxpayer 5 70000

Do you want default values (enter D) or enter your own (enter O)? d
Taxpayer # 1 SSN: 555555555 income $35,000.00 Tax is $9,800.00
Taxpayer # 2 SSN: 111111111 income $80,000.00 Tax is $20,000.00
Taxpayer # 3 SSN: 333333333 income $45,000.00 Tax is $12,600.00
Taxpayer # 4 SSN: 444444444 income $65,000.00 Tax is $6,500.00
Taxpayer # 5 SSN: 222222222 income $70,000.00 Tax is $19,600.00

——————————–

Taxpayer # 1 SSN: 444444444 income $65,000.00 Tax is $6,500.00
Taxpayer # 2 SSN: 555555555 income $35,000.00 Tax is $9,800.00
Taxpayer # 3 SSN: 333333333 income $45,000.00 Tax is $12,600.00
Taxpayer # 4 SSN: 222222222 income $70,000.00 Tax is $19,600.00
Taxpayer # 5 SSN: 111111111 income $80,000.00 Tax is $20,000.00
Press any key to continue . . .

"Get 15% discount on your first 3 orders with us"
Use the following coupon
FIRST15

Order Now