Blog
Notes on data structures & algorithms, system design, and things I learn along the way.
Learning DSA? Follow the structured path — ordered articles from recursion to dynamic programming.→The data structure behind autocomplete and spellcheck. How a trie stores words as shared character paths, and why lookups cost the length of the word — not the size of the dictionary.
How a heap keeps the smallest (or largest) element one lookup away, why it's stored in a plain array, and the sift-up/sift-down operations that keep it valid.
The two basic ways to store a sequence — arrays for instant access by position, linked lists for cheap inserts — what each operation costs, why arrays win most of the time anyway, and the two-pointer trick that detects a loop in a list in one pass with no extra memory: the tortoise and the hare.
DP is not a scary black box — it's recursion that stops repeating itself. Follow one problem from exponential recursion to a linear table, one cell at a time.
Breadth-first and depth-first search are the same algorithm with one data structure swapped. See both walk the same graph, and learn which to reach for.
Recursion feels like magic until you see the call stack. Here's the mechanical picture — frames pushing and popping — plus base cases, stack overflows, and tail calls.
Two of the highest-leverage array patterns in interviews and real code — how they turn nested O(n²) loops into a single O(n) pass, and when each one applies.
How binary search eliminates half the problem with every comparison, and how binary search trees turn the same idea into a data structure — with interactive animations.
How hash maps actually work — hashing, buckets, collisions, and resizing — with an animated walkthrough and a from-scratch implementation.
Why the classic interview question is really a lesson in composing data structures — with an animated walkthrough and two working implementations.
51 posts tagged DSA · page 5 of 6