LoriU LoriU
  • 01-03-2021
  • Computers and Technology
contestada

Create a Python program to solve a simple pay calculation.

Respuesta :

josiaharnold24 josiaharnold24
  • 01-03-2021

Answer:

def weeklyPaid(hours_worked, wage):  

   if hours_worked > 40:  

       return 40 * wage + (hours_worked - 40) * wage * 1.5

   else:  

       return hours_worked * wage  

 

 

hours_worked = 50

wage = 100

 

pay = weeklyPaid(hours_worked, wage)  

 

print(f"Total gross pay: Rs.{pay:.2f} ")

Explanation:

provides gross pay

Answer Link

Otras preguntas

if h(x) = −3x − 10, find h(−3). −19 −1 1 2.3
Complete the following sentence: You can verify the zeros of the function y=x^2 +x - 7 by using a graph and finding where the graph _______. A) is at a minimum
hydrogen cyanide is poisonous liquid that has a faint almond like smell. one molecule of hydrogen cyanide is made up of one hydrogen atom, one carbon atom,
Energy, growth, evolutionary, and ecological describe different biological _____.
Is there another way to write 7.05.
why is it important to set performance goals instead of outcome goals?
A regular hexagon is inscribed in a circle of radius 25 inches find the length of the sides of the hexagon. A regular hexagon is inscribed in a circle of radius
Why do some feel that it is not okay to use psychological research as a way to control behavior
Which of these tools is used to transfer a gene into an animal? a. molecular scissors B.vector C. ligase enzyme
How did the Roman Empire expand over time?