[01 / 04]Data StructuresO(n) bottom-up
Building a heap, from the bottom up
Why building a heap backwards runs in linear time.
Statewalk
Interactive essays for understanding systems.
Why building a heap backwards runs in linear time.
Stop guessing with +1 and <= : binary search is just finding a boundary.
Streaming database queries without recomputing the entire world.
Solve next-greater queries in one pass by letting the future settle the past.