PythiloMedium · 25 min · Task 79 of 100 · progress kept in this browser

Schedule tasks with cooldown

Return the least number of unit slots to execute letter tasks when equal letters need at least cooldown other slots between them. Idle slots are permitted; cooldown >= 0.

maximum, tied, cooldown = 3, 2, 2
print((maximum-1)*(cooldown+1)+tied)
Your task

Return the least number of unit slots to execute letter tasks when equal letters need at least cooldown other slots between them. Idle slots are permitted; cooldown >= 0.