Drill

ProblemsPython › events

What does this meeting cost

mediumeventsPython

Finance wants every meeting priced: length × attendees × hourly rate, rounded down.

meeting_cost(minutes: int, attendees: int, rate_per_hour: int) → int

Solve it in the editor →

Where you start

def meeting_cost(minutes: int, attendees: int, rate_per_hour: int) -> int:
    

Worked examples

CallResult
meeting_cost(30, 5, 100)250
meeting_cost(60, 3, 80)240
meeting_cost(45, 4, 60)180
meeting_cost(0, 5, 100)0

Hint

Multiply first, then integer-divide by 60.

Reference solution in Python
def meeting_cost(minutes: int, attendees: int, rate_per_hour: int) -> int:
    return (minutes * attendees * rate_per_hour) // 60

The same problem in another language

More events problems in Python