Question: 1. (20 pts.) Write a program that computes a person's income tax. Following tax laws are in effect: All taxpayers are charged a flat tax

1. (20 pts.) Write a program that computes a person's income tax. Following tax laws are in effect: All taxpayers are charged a flat tax rate of 20% All taxpayers are allowed a $10,000 standard deduction For each dependent, a taxpayer is allowed an additional $3,000 deduction Inputs: gross income (entered to the nearest penny), and number of dependents. Calculation: Taxable income gross income 10000 (3000 number of dependents) Tax Taxable income 0.20 Output: Print the tax rounded to 2 decimal places preceded by the text "Tax" Use a multi-line comment statement at the beginning of the program to describe the purpose of the program. Divide the program into three sections: input, calculation, and output. Use single line comment statements at the beginning of each section to identify the sections (save the module as Prob 1) 2. (20 pts) Write a program to print students' classification based on the number of credit hours completed. Classification based on credit hours completed is as follows: FR >30 and60 and 90 Credit hours must be between 0 and 150. If less than 0 or > 150, t should display an error message. (Use If/Then/Else structure) (Save the module as Prob 2) SO SR (20 pts) Write a program that takes hours worked and pay rate as inputs and calculates wages. wages hours worked X pay rate (hours worked multiplied by pay rate). The program displays wages at each iteration, and Total wages after the end of the program. The user terminates the program by entering a negative value for the pay rate. Total wages should be preceded by the text "Total wages Use While loop (Save the module as Prob 3) 3. (10 pts) Use a While loop to calculate the sum of odd integers from 3 to 15 (Save the module as Prob 4) 4. (10 pts) Use a For loop to calculate the sum of odd integers from 3 to 15 (Save the module as Prob 5 5
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
