Answer to Question #286096 in C++ for Muste

Question #286096

write the programme that implementes the following algorithms? start: read the total hours the employee has woked,Total hours. Read the hourly rate of pay for the employee,Hourly rate. gross salary=total hours*hourly rate. tax=gross salary *0.1 Net salary =gross salary-tax. Display net salary

1
Expert's answer
2022-01-10T00:24:16-0500
#include <iostream>



using namespace std;



int main() {



    double totalHour;
    cout << "Enter total hours you have worked: ";
    cin >> totalHour;
    double hourlyRate;
    cout << "Enter the hourly rate: ";
    cin >> hourlyRate;
    double grossSalary = totalHour * hourlyRate;
    double tax = grossSalary * 0.1;
    double netSalary = grossSalary - tax;
    cout << "Net Salary = " << netSalary<< endl;




    return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment