Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Lab 5 Instructions: Open the terminal and using vi/vim create a new script and name it lab5.txt Insert at the top of your file
Lab 5 Instructions: Open the terminal and using vi/vim create a new script and name it lab5.txt Insert at the top of your file a comment with your name, class and section number (e.g. #John Doe, EMT 2390L-ABC123). .In this lab you will create a script to figure out the Federal tax rate of an individual based on the income. Create a function display TaxRate that will: Ask the user to enter the income and store it in a variable named income. Using an if/elif statement, read the value of the variable income and display the corresponding tax rate according to the following table: Income $0 to $10,275. Tax Rate 10% $10,276 to $41,775. 12% $41,776 to $89,075. 22% $89,076 to $170,050. 24% $170,051 to $215,950. 32% $215,951 to $539,900. 35% $539,901 or more. 37% . In the body of the script, at the bottom of the file provide code to: Display a menu with the following options: 1- Get Tax Rate, 2-Quit: If the user enters 1, invoke the display Tax Rate function. If the user enters 2. exit the script.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started