Skip to content

Instantly share code, notes, and snippets.

@denoboi
denoboi / Coursera Python Assignment 4.6
Created February 5, 2021 09:44
Write a program to prompt the user for hours and rate per hour using input to compute gross pay. Pay should be the normal rate for hours up to 40 and time-and-a-half for the hourly rate for all hours worked above 40 hours. Put the logic to do the computation of pay in a function called computepay() and use the function to do the computation. The…
hrs = input("Saati gir pezo: ")
h = float(hrs)
hrt = input("Rate kac:")
r = float(hrt)
def computepay(a, b):
if (a <= 40):
islem = a * b
elif (a > 40):