Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please i need help with the solution C++ programming language below is listing 3.3 for reference 0 (Financial application: compute tax) Rewrite Listing 3.3, ComputeTax.con

please i need help with the solution
C++ programming language
image text in transcribed
below is listing 3.3 for reference
image text in transcribed
image text in transcribed
0 (Financial application: compute tax) Rewrite Listing 3.3, ComputeTax.con using arrays. For each filing status, there are six tax rates. Each rate is applied to a certain amount of taxable income. For example, from the taxable income of $400,000 for a single filer, $8,350 is taxed at 10%, (33,950-8,350) at 15% (82,250-33.950) at 25%, (171,550-82,550) at 28%, (372,550-82,250) at 33%, and (400,000-372,950) at 36%. The six rates are the same for all filing statuses, which can be represented in the following array: double rates[] = {0.10. 0.15 0.25, 0.28, 0.33, 0.36): The brackets for each rate for all the filing statuses can be represented in a two dimensional array as follows: int brackets[4][5] = {8350, 33950, 82250, 171550.372950} (16700, 67900, 137050, 20885,372950); /Single filer // Married jointly // or qualifying // widow(er) // Married separately, // Head of household {8350, 33950, 68525, 104425. 186475}, {11950, 45500, 117450, 190200, 372950} }; Suppose the taxable income is $400,000 for single filers. The tax can be computea as follows: tax = brackets[0][0] * rates [0] + (brackets[0][1] - brackets[0][0]) * rates [1] + (brackets[0][2] - brackets[0][1]) * rates [2] + (brackets[0][3] - brackets[0][2]) * rates [3] + (brackets[0][4] - brackets[0][3]) * rates [4] + (400000 - brackets[0][4]) * rates [5] es the solution to compute taxes for single filers. The complete solution is tells exercise LISTING 3.3 c 3.3 ComputeTax.cpp include > Status: input status 450 -200 1 Prompt the user to enter taxable income cout > income: 950 input income // Compute tax double tax = 0; compute tax prom sine if (status -- 0) // Compute tax for single filers if (income 8350) tax - income - 0.10; else if (income (tax - 100) / 100.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

Databases A Beginners Guide

Authors: Andy Oppel

1st Edition

007160846X, 978-0071608466

More Books

Students also viewed these Databases questions

Question

46. GivenMX(t).2.3et.5e3t, ndp(x), E(X), V(X).

Answered: 1 week ago

Question

What are the functions of top management?

Answered: 1 week ago

Question

Bring out the limitations of planning.

Answered: 1 week ago

Question

Why should a business be socially responsible?

Answered: 1 week ago

Question

Discuss the general principles of management given by Henri Fayol

Answered: 1 week ago