Data Structures & Algorithms
26 interactive visuals
16 Beginner10 Intermediate1 Advanced
Concepts6
Time ComplexityHow algorithms scale
BeginnerOpen
Space ComplexityWatch memory grow — O(1), O(n), and O(n²) side by sideBeginnerOpen
RecursionUnderstand recursion visually using factorial and FibonacciBeginnerOpen
MemoizationCache results to avoid recomputing the same subproblem twiceIntermediateOpen
FibonacciWhy naive recursion is O(2ⁿ) — and how memoisation fixes itBeginnerOpen
Sliding WindowTurn O(n²) subarray problems into O(n) with a moving windowIntermediateOpen
Data Structures6
ArraysO(1) random access, contiguous memory — the most fundamental data structure
BeginnerOpen
Linked ListO(1) head operations, O(n) access — pointer-linked nodes in memoryBeginnerOpen
Stack & QueueLIFO vs FIFO — two structures, two totally different ordersBeginnerOpen
Hash TableO(1) average get, set, and delete — the backbone of fast lookupsBeginnerOpen
HeapO(log n) insert and extract — the foundation of priority queuesIntermediateOpen
BST OperationsSearch, insert, and delete in O(log n) — with the in-order successor explainedIntermediateOpen
Sorting9
Bubble SortRepeatedly swapping adjacent elements
BeginnerOpen
Selection SortRepeatedly selects the smallest elementBeginnerOpen
Insertion SortBuilds a sorted list one element at a timeBeginnerOpen
Merge SortDivide, sort, and mergeBeginnerOpen
Quick SortPick a pivot, partition, repeat — sorting at its fastestIntermediateOpen
Shell SortInsertion sort with a shrinking gap — sort far-apart elements firstIntermediateOpen
Heap SortBuild a max-heap, then extract the largest element one by oneIntermediateOpen
Counting SortSort integers in O(n+k) — no comparisons, just countingBeginnerOpen
Radix SortSort by digits — no comparisons, just bucketingIntermediateOpen
Searching5
Binary SearchSearch by halving the range
BeginnerOpen
Linear SearchFinds an element by checking one value at a timeBeginnerOpen
Jump SearchO(√n) — jump forward in blocks, then scan back linearlyIntermediateOpen
Interpolation SearchO(log log n) on uniform data — smarter than binary by estimating positionAdvancedOpen
String MatchingFind every pattern occurrence in text — naive O(n·m) vs KMP O(n+m)IntermediateOpen