Skip to main content

VIVID CODE / ARTICLES

38 articles

Data StructuresAug 18, 2026

Fibonacci Heap: Delay the Cleanup

A practical explanation of Fibonacci heaps, including root lists, lazy meld, cascading cuts, degree consolidation, and amortized complexity.

Fibonacci heapsPriority queuesAmortized analysisRead article
Data StructuresAug 17, 2026

Leftist Heap: A Heap Born to Merge

Learn how leftist heaps preserve heap order while using the leftist property and right-spine merging to make meld operations efficient.

leftist heapheapspriority queuemeldable heapdata structuresheap operationsRead article
Data StructuresAug 13, 2026

Pairing Heap: A Priority Queue Driven by Meld

A practical explanation of pairing heaps, including multiway heap order, constant-time meld, insertion, extract-min, two-pass pairing, amortized complexity, implementation details, and comparisons with binary heaps and binary search trees.

pairing heappriority queuemeldable heapheap algorithmsamortized analysisextract-mindecrease-keydata structuresRead article
Data StructuresAug 13, 2026

Binary Heap: The Engine Behind Priority Queues

Learn how the heap property, complete binary-tree structure, array representation, sift-up, and sift-down support efficient priority queues and task scheduling.

heapsbinary heapspriority queuesalgorithmsdata structuresheapifytask schedulingRead article
Data StructuresAug 12, 2026

Binomial Heaps: Merging Like Binary Addition

A practical guide to binomial heap structure and the insert, merge, and extract-min operations built from binomial tree merging.

Binomial HeapsPriority QueuesAlgorithmsHeap Data StructuresBinary AdditionRead article
Data StructuresAug 11, 2026

Rope: The String Built for Editing

A practical guide to rope strings, including their tree structure, weight-based indexing, traversal, concatenation, splitting, and text insertion.

RopeStringsText EditorsTreesData StructuresRead article
Data StructuresAug 10, 2026

B+ Tree: The Real Database Index

A practical explanation of how B+ Trees differ from B-Trees, why data is stored only in leaves, how linked leaves support ordered range queries, and why databases favor this structure for indexing.

B+ TreeDatabase IndexingB-TreeTree AlgorithmsRange QueriesData StructuresRead article
Data StructuresAug 10, 2026

B-Tree: The Foundation of Database Indexing

A practical explanation of how B-Trees organize sorted keys, guide searches, handle insertion, split full nodes, and preserve balance—showing why databases use B-Trees as a foundation for indexing.

B-TreeDatabase IndexingDatabasesTree Data StructuresSearch TreesAlgorithmsRead article
Data StructuresAug 10, 2026

Binary Search Tree: The Art of Ordered Storage

A practical guide to binary search trees, covering their ordering invariant, search, insertion, deletion, in-order traversal, height-based complexity, and the O(n) degeneration caused by inserting already ordered values.

binary search treetree algorithmscomplexitysearchinsertiondeletiondata structuresRead article
Data StructuresAug 9, 2026

Fenwick Tree: Ranking on a Game Leaderboard

Learn how a Fenwick tree uses lowbit to maintain leaderboard score counts, answer prefix-sum ranking queries, and apply point updates in O(log n) time.

Fenwick TreeBinary Indexed TreeLeaderboardsPrefix SumPoint UpdateAlgorithmslowbitRead article
Data StructuresAug 9, 2026

Segment Tree: Computing HP on the Battlefield

Uses range-sum and point-update operations on unit HP in a game to explain how a segment tree supports both operations in O(log n).

segment treerange sumpoint updatealgorithmsdata structuresRead article
Data StructuresAug 9, 2026

Red-Black Tree: Balance Through Color

A practical explanation of how five color and path properties, recoloring, and rotations keep a Red-Black tree approximately balanced during insertion and deletion.

Red-Black TreeBalanced TreesTree AlgorithmsBinary Search TreesTree RotationsRead article