update max015,

This commit is contained in:
louiscklaw
2025-02-01 02:04:08 +08:00
commit 7099a8ed36
331 changed files with 43217 additions and 0 deletions

19
T04/test_2_6.py Normal file
View File

@@ -0,0 +1,19 @@
def computepay(hours, rate):
output = 0
hours = int(hours)
rate = float(rate)
if (hours > 40):
output = 40*rate + (hours-40)*rate*1.5
else:
output = hours*rate
return output
print('Input:')
hours = input('Enter Hours: ')
rate = input('Enter Rate: ')
pay = computepay(hours, rate)
print('Output:')
print(f"Pay: {pay}")