Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Write a C++ application called calcPay for a financial company. The goal of this

ID: 3765516 • Letter: W

Question

Write a C++ application called calcPay for a financial company. The goal of this program is to determine weekly gross pay based on an hourly rate and the number of hours worked in a month. Anyone working over 40 hours a week earns time-and-a-half. Show code and screenshots that it works.

The application would be based on the following concepts:

Prompt to enter the employee’s rate of pay

Prompt to enter how many weeks are in the current month (4 weeks or 5 weeks)

Prompt to enter the hours worked for the month (aka week)

Loop week1 < current month then

Calculate the pay for this week

Hours > 40 is time and a half

Loop week2 < current month then

Calculate the pay for this week

Hours > 40 is time and a half

Continue to prompt for hours worked and calculate the pay

When week = current month (or countdown to 0)

Add all the pay for the month together

Display total gross pay for the month

Explanation / Answer

#include #include #include using namespace std; void instructions(string &name, float &rate, float &sum); string getName(); float getRate(); float getHours(); float calcPay(float rate, float sum); float calcGross(float pay); float calcAmount(float gross); float calcNet(float gross, float with); void output(string name, float rate, float sum, float with, float gross, float net, float pay); int main() { string name, done; int counter; float rate, sum, gross, with, pay, net; instructions(name, rate, sum); calcPay(rate, sum); output(name, rate, sum, with, gross, net, pay); return 0; } void instructions(string &name, float &rate, float &sum) { name = getName(); rate = getRate(); sum = getHours(); } string getName() { string name, done; cout
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote