Design Task Manager
Track each task in a map and a max heap of priorities, skipping heap entries that went stale after an edit or removal.
Track each task in a map and a max heap of priorities, skipping heap entries that went stale after an edit or removal.