Answered step by step
Verified Expert Solution
Question
1 Approved Answer
COMP 1 5 0 - Spring 2 0 2 4 W 2 Lab Instructions Your task is to write a program that will prompt the
COMP Spring
W Lab Instructions
Your task is to write a program that will prompt the user to enter values, as I described in the calorie calculator program that was shared during lecture last week, while using the language CThe calorie calculator application that we went over in class will be available on Canvas for your reference, located under the weekly WebEx video.
You will need to have the program accept the values into appropriate variables, calculate the total price of "something", and then display it to the user.
The paycheck calculator program calculates a user's gross weekly and take home pay. As with the calorie calculator, the formulae are provided for you below.
Console
Paycheck Calculator
Hours Worked:
Hourly Pay Rate:
Gross Pay:
Tax Rate:
Tax Amount:
Take Home Pay:
Specifications
The formula for calculating gross pay is:
gross pay hours worked hourly rate
The formula for calculating tax amount is:
tax amount gross pay tax rate
The formula for calculating take home pay is:
take home pay gross pay tax amount
The tax rate should be but the code should store the tax rate in a variable. That way, you can easily change the tax rate later, just by changing the value that's stored in the variable.
The program should accept decimal entries like and
The program should round the results to a maximum of two decimal places.
The source code must have a block comment at the beginning that documents the student's name, course number, lab number, and a brief description of what the program does. Be sure to use meaningful variable names and place comments within the code to explain what the code is doing. Compress the entire solution folder structure into a single zipped file named Lastname,FirstnameLabX.zip, where last name and first name are your last name and first name respectively and the is the lab number and the version that you were assigned.
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