Lessons
43 lessons in computer-science · intermediate · page 1 of 2
Learning paths in computer-science
Browse all paths- Computer Scienceintermediate
Search Relevance: From BM25 to Hybrid
Vector search did not replace keyword search; production search runs both, because they fail in opposite places. This path builds relevance engineering from the ground up: the inverted index and the analysis decisions baked into it, BM25 and its saturation arithmetic, hybrid retrieval with reciprocal rank fusion, and the evaluation machinery, judgment sets, NDCG, position bias, that tells you whether any of it actually got better.
4 lessons · certificate - Computer Scienceintermediate
Core Data Structures: Hash Tables, Trees, Heaps, and Tries
Four structures cover most of what production code actually needs, and each exists because the others cannot answer one particular question. This path builds them from the mechanism up: why a hash table's constant lookup costs you all ordering, why sorted input destroys an unbalanced tree and what a rotation repairs, why a heap keeps only enough order to surface the smallest item, and why routers and autocomplete need a trie. You will finish able to pick the right one from the question being asked.
4 lessons · certificate - Computer Scienceintermediate
How CPUs Actually Work: Pipelines, Caches, and Performance
Two processors at the same clock speed can differ several-fold in real work done, and the reason is never the clock. This path builds the model that explains it: how a pipeline overlaps instructions and what a mispredicted branch costs, how a core issues several instructions per cycle and reorders them, why a DRAM access is roughly sixty times an L1 hit, and how the roofline model tells you whether optimising arithmetic is worth any effort at all. You will finish able to predict which loop is faster and say why.
4 lessons · certificate - Computer Scienceintermediate
Information Theory and Compression
Shannon proved in 1948 that information has a hard, measurable limit, and nearly every file, stream and disk you touch is built on that result. This path works through it. You will learn what entropy really measures and why cross-entropy is the loss function that trains language models, how Huffman and arithmetic coding approach the compression floor, where lossy formats like JPEG and AAC actually discard information and why that is a deliberate tradeoff, and how error-correcting codes let data survive a noisy channel.
4 lessons · certificate - Computer Scienceintermediate
How Computer Networks Actually Work
A request leaves your browser and arrives somewhere across the world in tens of milliseconds. This path follows it the whole way down. You will learn how headers nest as a packet is built, why MTU mismatches cause the classic bug where small requests work and large ones hang, how routers choose a path by longest prefix match and how a BGP mistake can take a network off the internet, how TCP turns an unreliable network into an ordered stream and what congestion control is really negotiating, and why HTTP/3 abandoned TCP for QUIC.
4 lessons · certificate - Computer Scienceintermediate
How Operating Systems Actually Work
Every program runs on top of a kernel making decisions for it: which thread gets the CPU, which pages stay in memory, when a write really reaches disk. This path opens that layer up. You will learn what a process actually is and what a context switch costs, how virtual addresses become physical ones through page tables and the TLB, what happens when code crosses into kernel mode and why that crossing is expensive, and how the page cache and fsync decide whether your data survives a crash. It closes on containers as ordinary kernel features rather than magic.
4 lessons · certificate
Individual lessons
- Computer Scienceintermediate
Measuring Relevance: Judgments, NDCG, and the Click Trap
Search quality arguments end when there is a number, and begin again over whether the number is honest. This lesson builds offline evaluation from its atoms: a judgment set, precision and recall at k, MRR for known-item queries, and NDCG computed by hand for graded relevance. Then the online half: clicks, position bias, and why the top result gets clicked even when it is wrong.
7 steps·~11 min - Computer Scienceintermediate
Lexical Meets Vector: Hybrid Search and Rank Fusion
Vector search did not replace keyword search, because the two fail in opposite places: BM25 cannot see that laptop and notebook mean the same thing, and embeddings cannot see that SKU-4471-B is not approximately anything. This lesson maps the two failure surfaces, then builds the production answer: run both retrievers and fuse the rankings, with reciprocal rank fusion done by hand.
7 steps·~11 min - Computer Scienceintermediate
BM25: How Lexical Relevance Is Actually Computed
Matching finds candidates; scoring orders them, and the ordering is the product. This lesson builds BM25, the default ranking function of Lucene, Elasticsearch and OpenSearch, from its three ingredients: rare terms count more, repeated terms saturate, and long documents get discounted. With the formula, the two tuning knobs, and the saturation curve computed by hand.
7 steps·~11 min - Computer Scienceintermediate
The Inverted Index, and Why Analysis Decides Everything
Search does not scan documents; it looks up precomputed answers. This lesson builds the inverted index from first principles, then covers the pipeline that feeds it: tokenization, normalisation, stemming and synonyms, and why an analysis mistake made at index time cannot be fixed at query time. Includes the classic failure where a product SKU becomes unfindable.
7 steps·~11 min - Computer Scienceintermediate
How a Float Is Stored, and What That Rules Out
Floating point is not a slightly inaccurate version of real numbers. It is a finite set of values, spaced logarithmically, with exact rules. This lesson builds the IEEE 754 layout, shows why 0.1 cannot be represented, and derives the one error bound that every later result depends on.
8 steps·~12 min - Computer Scienceintermediate
The Bargain: Bounded Memory for Bounded Error
Answering set questions exactly costs memory proportional to the data, which fails once the data does not fit. Probabilistic data structures accept a quantified error in exchange for memory that stays constant. This lesson establishes what that trade buys, and why the shape of the error matters more than its size.
8 steps·~12 min - Computer Scienceintermediate
From Scene to Pixel: The Transform Chain
Every renderer answers one question first: at this pixel, which surface is visible? Getting there means moving geometry through five coordinate spaces. This lesson builds that chain, explains why a fourth coordinate is not a trick, and shows where depth precision quietly goes wrong.
9 steps·~14 min - Computer Scienceintermediate
Finite Memory and What It Cannot Recognise
A machine with a fixed number of states can recognise a surprising amount, and then hits a wall that no amount of cleverness moves. This lesson builds the finite automaton, shows that regular expressions are the same thing in different notation, and proves by counting that balanced parentheses are out of reach.
9 steps·~14 min - Computer Scienceintermediate
Optimal Substructure: The Property Both Techniques Need
Dynamic programming and greedy algorithms both rest on a structural property the problem either has or does not have. This lesson establishes it precisely, shows a problem that lacks it, and separates the three properties that decide which technique applies.
9 steps·~14 min - Computer Scienceintermediate
Tries and Radix Trees: Structures Keyed by Prefix
A trie stores keys in their spelling rather than hashing them, which buys the one query a hash table cannot answer: find everything starting with this. This lesson covers the trie, the memory problem that makes it impractical, and the radix compression that fixes it and routes the internet.
9 steps·~14 min - Computer Scienceintermediate
Heaps and Priority Queues: Keeping Only the Top
A heap is the structure for when you need the smallest item repeatedly but never need the whole set sorted. This lesson builds the binary heap as an array, derives why building one costs linear rather than n log n time, and shows the top-k pattern that makes it worth knowing.
9 steps·~14 min - Computer Scienceintermediate
Balanced Search Trees: Why Rotations Exist
A binary search tree is elegant until sorted input turns it into a linked list. This lesson explains how balance is enforced: the rotation as the one legal repair, what red-black and AVL trees each guarantee, and why databases use B-trees with hundreds of children instead.
9 steps·~14 min - Computer Scienceintermediate
Hash Tables: Collisions, Load Factor, and Swiss Tables
A hash table promises constant-time lookup, and the promise holds only because of how it handles collisions. This lesson builds one from the array up: hashing, chaining versus open addressing, why load factor is the tuning dial, and how modern tables scan sixteen slots at once.
10 steps·~15 min - Computer Scienceintermediate
Why Most Code Is Memory Bound: The Roofline Model
Most real code never approaches a processor's arithmetic peak because it cannot be fed fast enough. The roofline model makes that concrete: plot operational intensity against achievable performance and the binding constraint becomes visible. This lesson covers the model, bandwidth versus latency, and the layout changes that follow.
9 steps·~14 min - Computer Scienceintermediate
The Cache Hierarchy and Why Locality Decides Speed
DRAM is roughly two orders of magnitude further away than a register, so processors interpose several levels of cache. This lesson covers measured latencies at each level, cache lines and associativity, the three kinds of miss, and why identical algorithms differ tenfold based on access order alone.
10 steps·~15 min - Computer Scienceintermediate
Superscalar and Out-of-Order Execution
Modern cores issue several instructions per cycle and execute them in whatever order their inputs become ready, while still appearing to run the program strictly in order. This lesson covers register renaming, the reorder buffer, the scheduler, and why the instruction window exists at all.
9 steps·~14 min - Computer Scienceintermediate
CPU Pipelines: Throughput, Hazards, and Stalls
A processor does not execute one instruction at a time. It overlaps them in a pipeline, which raises throughput without making any single instruction faster. This lesson covers pipeline stages, the three classes of hazard, forwarding, the load-use stall, and why a mispredicted branch is expensive.
10 steps·~15 min - Computer Scienceintermediate
Lossy Compression and the Rate-Distortion Tradeoff
Lossy compression is not lossless compression done badly. It is a deliberate trade of fidelity for rate, governed by a curve Shannon derived in 1959. This lesson covers rate-distortion theory, transform coding and the DCT, where JPEG actually discards information, perceptual coding in audio, motion compensation in video, and learned codecs.
11 steps·~17 min - Computer Scienceintermediate
Channel Capacity and Error-Correcting Codes
Shannon proved that a noisy channel still has a rate at which errors vanish. This lesson works a Hamming code by hand, follows Reed-Solomon into CDs, QR codes and deep space, reaches the capacity-approaching codes inside 5G, and ends on erasure coding versus replication in distributed storage.
12 steps·~18 min - Computer Scienceintermediate
Source Coding: Huffman, Arithmetic Coding and ANS
Entropy is a hard floor on lossless compression, and this lesson shows how coders approach it. Build a Huffman tree by hand, see exactly where it wastes bits on skewed sources, then follow the fix through arithmetic coding to asymmetric numeral systems, the entropy stage inside Zstandard.
11 steps·~17 min - Computer Scienceintermediate
Entropy: Measuring Information in Bits
Shannon's entropy measures the average surprise of a source, in bits, and it sets a hard floor on compression. Build it up from surprisal through joint and conditional entropy, mutual information, KL divergence and cross-entropy, with every number worked out by hand.
10 steps·~15 min - Computer Scienceintermediate
DNS, HTTP, and the Move to QUIC
Before a byte of HTTP moves, a name has to become an address. Follow the full resolution path from stub resolver to authoritative server, see how TTLs govern change, then trace head-of-line blocking from HTTP/1.1 through HTTP/2's TCP problem to HTTP/3 running on QUIC over UDP.
12 steps·~18 min - Computer Scienceintermediate
TCP: Reliability, Windows, and Congestion
TCP turns a lossy packet service into an ordered byte stream, and almost every performance surprise on the internet comes from how it does that. Work through the handshake, cumulative ACKs, retransmission timers, the two windows, slow start and AIMD, CUBIC versus BBR, bufferbloat, and when to reach for UDP instead.
13 steps·~20 min - Computer Scienceintermediate
IP Addressing and How Routing Decides
IP is the only layer the whole internet agrees on. Work through IPv4 and IPv6 addressing, CIDR subnet math by hand, what a routing table really holds, longest-prefix match, why NAT ended end-to-end addressing, and how one BGP announcement can pull a network off the internet.
12 steps·~18 min

