Search
⌘K

Leetcode 621. Task Scheduler

Given tasks labeled A–Z and a cooldown n, compute the minimum number of CPU intervals (including idles) to finish all tasks so that identical tasks are separated by at least n intervals; the core challenge is arranging high-frequency tasks to minimize idle slots, typically solved by counting task frequencies and placing the most frequent tasks first (or simulating with a greedy/heap approach).


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.