For example, an individual's wage for one month is 3800 dollars. After subtracting 800 dollars of fees, they apply the remaining 3000 dollars to each of the income brackets. Bracket 1 is completely filled with 500 dollars, bracket 2 is completely filled with 1500 dollars, and bracket 3 gets the remaining 1000 dollars. The rates applied to the brackets are respectively 5%, 10%, and 15%. Thus the total wage tax for that month is 500×5% + 1500×10% + 1000×15% = 325 (dollars). The calculating process is outlined in the figure given on the left.You must write a program to help a company keep track of the taxes they have to pay for one year, given the information of all of their payouts (the type of payout, time of payout, and the amount paid). Your program must find the sum of both the wage tax and income tax for all of their employees.
đang được dịch, vui lòng đợi..
