# Arup Guha
# 10/13/2020
# Solution to COP 2930 Program 6, Part A: Testing Regular Pay function

# Pre-conditions: payPerHour is a positive floating pt 
#  number representing the pay per hour. regWorkWeek
#  represents the number of hours in a regular work week
#  (int). hoursWorked is the number of hours the employee
#  worked (int).
# Post-condition: Returns the regular pay for the employee.
def regularPay(payPerHour, regWorkWeek, hoursWorked):

    # Here we multiply by hours worked.
    if hoursWorked <= regWorkWeek:
        return payPerHour*hoursWorked

    # If we get here, they get full pay no matter how much they worked.
    return payPerHour*regWorkWeek

# Test cases I provided.
def testRegularPay():
    print(regularPay(8.25, 40, 30))
    print(regularPay(12.50, 30, 40))
    print(regularPay(9.99, 80, 80))

# Run it!
testRegularPay()
