Build a Heap-Based Task Scheduler
sift up/down and O(n) heapify
Challenge 3 of Indexes & StructuresIntermediate~55 min
Build a binary min-heap from scratch and grow it into a real task scheduler. You will implement push and sift-up, then pop and sift-down, an O(n) heapify, a priority queue that breaks ties by insertion order, and finally a top-K selector. No heapq, no imports, just an array and the parent/child index math that makes heaps fast.