Question: Write a Python program (payrollpy) that does the following: Print a message that says Welcome to the Payroll Manager! Define a function (payroll calculator) that

 Write a Python program (payrollpy) that does the following: Print a

Write a Python program (payrollpy) that does the following: Print a message that says "Welcome to the Payroll Manager!" Define a function (payroll calculator) that has the following three parameters: employee name, hours worked that week, and pay rate in dollars per hour. In the payroll_calculator, calculate the employee's salary as the number of hours worked multiplied by the rate. If the employee has worked more than 40 hours, then calculate overtime as 1.5 times the regular pay rate and add that to the salary. When the total salary has been calculated, print the name, hours worked and the salary in one line. Define the main function that contains five calls to the payroll calculator function with various names, hours worked, and pay rates. Make sure to call the main0 function in your program. Make sure to test your program such that it works with different pay rates and hours worked. Note. This program has NO user input

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!