Glossary: Programming and Algorithms
Every term Programming and Algorithms defines, from A to Z, with the section that teaches it. A section that uses a term from elsewhere, in this book or another, also lists it under “Concepts from other sections” at the top of the page.
432 terms
Symbols
Section titled “Symbols”- 0/1 knapsack: choosing a subset of items, each used at most once, to maximize total value within a capacity; with a single row of storage the capacity loop runs backwards so each item is counted at most once. Taught in Chapter 9: Dynamic programming
- Abstract Equality: the coercing algorithm behind
==, as opposed to the non-converting===. Taught in 17.4 Predicting TypeScript output - Accept interfaces, return structs: the Go guideline to take parameters as small interfaces, so callers can pass anything that fits, and to return concrete types, so methods can be added later without breaking callers. Taught in Chapter 20: Go
- Ad-hoc polymorphism: a different implementation per type, chosen by the types involved (overloading, typeclasses, traits, interfaces). Taught in 2.4 Generics at runtime and language comparison
- Adjacency list: a per-vertex list of outgoing edges; O(V + E) space for the whole graph. Taught in 18.6 Graph as an adjacency list
- Adjacency matrix: a table whose entry records whether, or with what weight, an edge joins and ; it gives edge lookup at space, which suits dense graphs. Taught in Chapter 8: Graphs
- Affinity routing: sending requests with the same prefix to the same engine so its prefix cache stays warm. Taught in 15.9 A consistent hash ring with bounded loads
- aggregate: a function such as
COUNT,SUM, orMAXthat turns the rows of a group into one value. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - Algebraic data type (ADT): a type built from sums (“one of these variants”) and products (“all of these fields”), such as a Rust
enumwith payloads; with exhaustive matching, every case must be handled explicitly. Taught in Chapter 21: Rust - alignment: the power of two that an object’s address must be a multiple of. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- Alignment: the requirement that an object’s address be a multiple of some power of two. Taught in 18.8 Arena allocator
- Allocator equality: two allocators compare equal when memory from one can be freed through the other. Taught in 19.9 Memory pool allocator
- Amortised cost: the average cost per operation over a worst-case sequence of operations, here O(1) per push even though one push in many is O(n). Taught in 18.1 Dynamic array
- Amortized cost: the total cost of a sequence of operations divided by their number. Taught in 15.1 A growable array
- amortized O(1): constant average cost per operation over a long sequence, as with geometric growth. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- Arc share: the fraction of the ring a node owns, and so the expected fraction of keys it receives. Taught in 15.9 A consistent hash ring with bounded loads
- Arena: a
Vecthat owns every node, with nodes linked by index. Taught in 15.7 A radix tree over token ids - Arena (bump) allocator: an allocator that serves requests by advancing an offset and frees all allocations at once. Taught in 18.8 Arena allocator
- AVL tree: a self-balancing binary search tree that keeps the heights of every node’s two subtrees within one of each other by rotating after insertions, which guarantees height and operations. Taught in Chapter 7: Trees
- Back edge: an edge found during depth-first search that points to a node still in progress on the current path; in a directed graph, tracked with three node states (unvisited, in progress, visited), a back edge is exactly a cycle. Taught in Chapter 8: Graphs
- backpressure: a slow consumer slowing its producer, so memory between them stays bounded. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper
- Backpressure: slowing the producer when the consumer cannot keep up, here by blocking
submiton a full queue. Taught in 18.7 Thread pool - Backtracking: depth-first search over a tree of partial solutions that makes a choice, recurses, and undoes the choice, abandoning any branch that cannot lead to a valid solution; it enumerates subsets, permutations, and solutions to constraint problems. Taught in Chapter 11: Backtracking
- Backward-shift deletion: moving the following run back one slot after a removal, instead of leaving a tombstone. Taught in 15.5 A Robin Hood hash map
- Balance factor: the height of a node’s left subtree minus the height of its right subtree; an AVL tree keeps it in , and its sign pattern after an insertion decides between a single and a double rotation. Taught in Chapter 7: Trees
- Base case: an input on which a recursive function returns directly without calling itself; together with an input that strictly shrinks on every call, it guarantees that the recursion terminates. Taught in Chapter 13: Recursion and divide-and-conquer
- Binary exponentiation / fast exponentiation: computing by squaring and multiplying by once more when is odd, in multiplications; the same idea gives matrix and modular exponentiation. Taught in Chapter 13: Recursion and divide-and-conquer
- Binary heap: a complete binary tree in an array in which no child comes out before its parent. Taught in 15.6 A binary heap with lazy deletion
- Binary search: a search that keeps an interval known to contain the answer and halves it with one comparison per step, taking steps; it needs a monotonic predicate, not necessarily a sorted array. Taught in Chapter 5: Binary search
- Binary search on the answer: binary searching over the range of possible answers with a monotone feasibility check, which turns an optimization problem (“the smallest capacity that works”) into decision problems (“does this capacity work?”). Taught in Chapter 5: Binary search
- Binary search tree (BST): a binary tree in which every node’s value is greater than every value in its left subtree and less than every value in its right subtree, so a search follows one root-to-leaf path and an in-order traversal yields the values in sorted order. Taught in Chapter 7: Trees
- Bit mask: an integer whose set bits select positions, such as
1 << ifor biti; OR with it sets the bit, AND with its complement clears it, XOR toggles it, and AND tests it. Taught in Chapter 12: Math and bit manipulation - Bitmask DP: dynamic programming whose state includes a subset of up to about 20 items encoded as the bits of an integer, giving states; used for the Travelling Salesman Problem and subset partitioning. Taught in Chapter 9: Dynamic programming
- Block expression: a block whose value is its final expression when that expression has no trailing semicolon. Taught in 17.3 Predicting Rust output
- Block table: the per-sequence list of KV block ids, one per 16 tokens. Taught in 15.1 A growable array
- Blocking queue: a queue whose operations wait, rather than fail, when it is full or empty. Taught in 19.4 Thread-safe queue
- Bloom filter: an -bit array with hash probes per item, answering membership with no false negatives. Taught in 15.8 A Bloom filter
- borrow: use of a value through a shared (
&) or exclusive (&mut) reference without taking ownership. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP - Borrow checker: the part of the Rust compiler that enforces ownership and borrowing: any number of shared references (
&T) or exactly one mutable reference (&mut T), and no reference outliving the value it points at; it rejects use-after-free and data races at compile time. Taught in Chapter 21: Rust - Bottom-up DFS: a tree recursion that solves both subtrees first and then combines their results with the node’s own value (post-order); it fits problems where a node’s answer depends on its children’s answers, such as height, diameter, and balance. Taught in Chapter 7: Trees
- Bottom-up DP / tabulation: filling a table of subproblem answers in an order where each entry’s dependencies are already computed, with no recursion; the iterative way to implement dynamic programming. Taught in Chapter 9: Dynamic programming
- bounded channel: a channel with a fixed capacity whose
sendwaits while it is full. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper - Bounded loads: a cap of per node, with over-cap keys walking clockwise to the next node below it. Taught in 15.9 A consistent hash ring with bounded loads
- Bounded quantification: parametric polymorphism restricted to types below a bound, as in
T: Ord. Taught in 2.4 Generics at runtime and language comparison - Branching factor: the number of choices at each node of a search tree; a backtracking search costs roughly the branching factor raised to the depth, such as for subsets and for permutations. Taught in Chapter 11: Backtracking
- Branded type: a primitive type intersected with a phantom marker, such as
number & { __brand: 'USD' }, so values with the same representation but different meanings are not interchangeable; nominal typing inside a structural type system. Taught in Chapter 23: TypeScript - Breadth-first search (BFS): traversal in order of hop distance using a FIFO queue. Taught in 18.6 Graph as an adjacency list
- broadcasting: numpy’s rule for treating differently shaped operands as one shape by stretching size-1 axes with stride 0. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- BUD analysis: justifying an optimization by naming the bottleneck, the unnecessary work, and the duplicated work. Taught in Chapter 27: Case Study: Order Book Matching
- buffer: the flat block of memory that holds an array’s elements. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- C-contiguous: row-major layout, with the last axis packed and each earlier stride equal to the next stride times the next size. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- Cached hash: storing an entry’s hash beside it to skip rehashing on growth and to reject mismatches cheaply. Taught in 18.9 String interning
- Call-site
this: the rule that an ordinary function’sthisis set by how it is called, not where it is defined. Taught in 17.4 Predicting TypeScript output - cancellation: raising
CancelledErrorat theawaita task is paused at, so its cleanup runs and the error propagates. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency - cancellation by drop: a dropped future stops at its last
.await, running destructors and nothing after. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper - Capacity: the number of elements the current buffer can hold, as distinct from the number it does hold (the length). Taught in 18.1 Dynamic array
- Case class: an immutable Scala class whose constructor parameters become fields and for which the compiler generates structural equality, copying, and pattern-matching support; Scala’s standard way to model data. Taught in Chapter 25: Scala
- Cell: the object through which a closure refers to a variable of an enclosing scope. Taught in 17.2 Predicting Python output
- cgroup: a kernel control group that limits the CPU time and memory a process may use. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- channel: a typed pipe that passes values between goroutines and synchronizes them. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- Checked exception: a Java exception that a method must declare in its
throwsclause and that callers must catch or declare in turn, unlike unchecked exceptions, which need neither. Taught in Chapter 26: Java - Choose, explore, unchoose: the loop at the core of backtracking: add a candidate to one shared, mutable partial solution, recurse, then remove it, so every branch sees exactly the state its parent left. Taught in Chapter 11: Backtracking
- Chunk: a large allocation from the system, carved into many blocks. Taught in 19.9 Memory pool allocator
- client streaming RPC: a call in which the client sends many messages and receives one reply after closing its side. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- Closest pair of points: finding the two nearest points in the plane in by splitting on , solving each half, and checking only a strip around the dividing line, where each point needs comparing with a constant number of others. Taught in Chapter 13: Recursion and divide-and-conquer
- Comma-ok receive:
v, ok := <-ch, whereokis false once a closed channel is drained. Taught in 17.1 Predicting Go output - commit: a git snapshot of the tracked files plus metadata and a parent pointer, named by its hash. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- Compaction: dropping stale entries and re-heapifying once they outnumber live ones. Taught in 15.6 A binary heap with lazy deletion
- Complement lookup: a one-pass hash-map pattern that, for each element, checks whether the partner it needs (such as
target - x) has already been seen and only then records the element; it finds pairs in instead of comparing every pair in . Taught in Chapter 3: Arrays and hashing - Complete binary tree: a tree with every level full except possibly the last, which is filled left to right; it is what makes the array layout work. Taught in 18.4 Binary heap
- Comptime / compile-time execution: Zig’s mechanism for running ordinary Zig code during compilation; generics are functions that take and return types at compile time, replacing templates, macros, and separate generics syntax. Taught in Chapter 24: Zig
- Concept: a named compile-time predicate on template arguments, checked at the point of use. Taught in 19.8 Graph with concepts
- Condition variable: a primitive that lets a thread sleep until another thread signals that shared state may have changed. Taught in 18.7 Thread pool
- Conditional type: a type of the form
A extends B ? X : Ythat chooses between two types, withinferto capture part of a matched type; it is the branching construct of type-level computation. Taught in Chapter 23: TypeScript - Consistent hashing: placing nodes and keys in one hash space so that a membership change moves only nearby keys. Taught in 15.9 A consistent hash ring with bounded loads
constexpr: a function or variable that may be evaluated at compile time. Taught in 19.3 Compile-time matrix- constraint: a rule (
PRIMARY KEY,NOT NULL,CHECK,DEFAULT) the database enforces on every write. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - Constraint propagation: shrinking the domains of unassigned variables after each assignment by removing values that can no longer be consistent, as AC-3 does, so dead ends are found before the search recurses into them. Taught in Chapter 11: Backtracking
- Constraint satisfaction problem (CSP): a problem of assigning each variable a value from its domain so that every constraint holds, as in Sudoku, N-Queens, and map coloring; solved by backtracking over the variables with a consistency check. Taught in Chapter 11: Backtracking
- container: a process started with its own namespaces and a cgroup, sharing the host’s kernel. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
container_of: a macro that computes the address of an enclosing struct from the address of one of its members. Taught in 18.3 Intrusive linked listContent-Length: the decimal count of bytes in a message body. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up- context: a value carrying a cancellation signal, its reason, and an optional deadline down a call tree. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- Context manager: an object with
__enter__and__exit__methods, used in awithstatement, so the setup and cleanup of a scoped resource happen on every exit path, including exceptions. Taught in Chapter 22: Python - Contextual conversion: an implicit use of
explicit operator boolpermitted only in conditions such asif (p)and!p. Taught in 19.2 UniquePtr - Control byte: one byte per slot holding EMPTY, DELETED, or the key’s 7-bit fingerprint. Taught in 15.2 A Swiss table
- controller: a control-plane loop that watches one kind of object and acts to make the world match it. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Convex hull trick: a DP optimization for transitions that minimize or maximize over a set of linear functions, keeping only the lines on their lower or upper envelope so each transition is a fast query. Taught in Chapter 16: Competitive Programming
- cooperative multitasking: scheduling in which a coroutine is never interrupted and gives up control only at an
await. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency - copy: an array with its own buffer, independent of the original. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- Copy-and-swap: implementing assignment by copying into a temporary and swapping, so failure cannot damage the target. Taught in 19.1 Vector
- coroutine: a paused computation returned by calling an
async deffunction; it runs only when driven and yields atawait. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency - Coroutine: a function that can suspend and later resume, keeping its locals in a heap-allocated frame. Taught in 19.6 Coroutine generator
- Coroutine handle: a non-owning pointer to a coroutine frame, used to resume, query, and destroy it. Taught in 19.6 Coroutine generator
- Count-min sketch: a array of counters with one hash function per row; an insertion increments one counter in each row and a query returns the minimum of its counters, which never undercounts and overcounts by at most with probability at least . Taught in Chapter 14: Probabilistic data structures
- Counting Bloom filter: a Bloom filter whose bits are replaced by small counters, so an element can be deleted by decrementing its counters; it supports deletion at the cost of several times the space. Taught in Chapter 14: Probabilistic data structures
- crate: one Rust compilation unit, either a library or a binary. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP
- CRC-32C: a 32-bit Castagnoli checksum over a payload, used to detect corruption. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- CRLF: the two bytes
\r\nthat end every line of an HTTP/1.1 head. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up - Crossed book: a book in which the best bid is at or above the best ask; it must never happen. Taught in Chapter 27: Case Study: Order Book Matching
- CRTP: the curiously recurring template pattern,
class D : Base<D>, letting the base call the derived type statically. Taught in 19.5 Expression templates
- Dangling pointer: a pointer to memory that has been freed or moved, which is undefined behaviour to dereference. Taught in 18.1 Dynamic array
- Dangling reference: a reference to an object whose lifetime has ended. Taught in 19.5 Expression templates
- deadline: a fixed point in time after which work is cancelled, unlike an idle timeout that restarts on activity. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- decay: the conversion of an array’s name to a pointer to its first element. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- Default value evaluation: default expressions are evaluated once, when
defruns, and stored in__defaults__. Taught in 17.2 Predicting Python output - Deferred call: a function call scheduled with Go’s
deferto run when the surrounding function returns; deferred calls run in last-in, first-out order, which makes them the place for cleanup. Taught in Chapter 20: Go - Deleter: the callable a smart pointer uses to destroy what it owns. Taught in 19.2 UniquePtr
- Deployment: an object declaring a Pod template, a replica count, and an update strategy, implemented through ReplicaSets. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Depth-first search (DFS): traversal that follows one path as far as possible before backtracking, using a stack. Taught in 18.6 Graph as an adjacency list
- Detection idiom: a trait built with
std::void_tand partial specialisation that reports whether an expression is well formed. Taught in 19.3 Compile-time matrix - digest: the SHA-256 hash that names a layer or image immutably; a tag, by contrast, is a movable pointer. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Dijkstra’s algorithm: single-source shortest paths for non-negative edge weights that repeatedly pops the closest unsettled node from a priority queue, relaxes its edges, and skips popped entries whose distance is stale; with a binary heap. Taught in Chapter 8: Graphs
- Discriminated union: a union of object types that share a literal tag field such as
kind, so checking the tag narrows the value to one member; withnever, the compiler can verify that aswitchhandles every case. Taught in Chapter 23: TypeScript - Displacement: how many slots past its home an entry sits. Taught in 15.5 A Robin Hood hash map
- Divide and conquer / divide-and-conquer: an algorithm design that splits a problem into independent subproblems, solves them recursively, and combines their results; unlike dynamic programming the subproblems do not overlap, and the gain comes from better asymptotics, as in merge sort. Taught in Chapter 13: Recursion and divide-and-conquer
- Double hashing: generating probes from two hashes. Taught in 15.8 A Bloom filter
- DP state: the parameters that identify one subproblem in dynamic programming, such as an index, a pair of prefixes, or a remaining capacity; choosing it well is the main difficulty of a DP problem. Taught in Chapter 9: Dynamic programming
- DP transition: the recurrence that expresses a DP state’s answer in terms of smaller states, such as
dp[i] = max(dp[i-1], dp[i-2] + nums[i]); together with the base cases it defines the whole computation. Taught in Chapter 9: Dynamic programming - Drop: running a value’s destructor when its owner goes out of scope; locals drop in reverse declaration order. Taught in 17.3 Predicting Rust output
- Dummy head node: a placeholder node placed before a linked list’s real head so that every real node has a predecessor; insertions, deletions, and merges then need no special case for the head, and the result is
dummy.next. Taught in Chapter 6: Linked lists - Dunder method: a method named with double underscores, such as
__iter__or__eq__, that Python calls to carry out an operator, attribute lookup, iteration, orwithblock; defining them makes your types behave like built-ins. Taught in Chapter 22: Python - Dynamic programming (DP): solving a problem by breaking it into overlapping subproblems and storing each subproblem’s answer the first time it is computed, which turns an exponential recursion into a polynomial computation. Taught in Chapter 9: Dynamic programming
- Edit distance: the minimum number of insertions, deletions, and substitutions that turn one string into another, computed by a two-sequence DP over pairs of prefixes in . Taught in Chapter 9: Dynamic programming
- errdefer: a Zig statement that schedules cleanup to run only if the enclosing scope exits with an error, which undoes a partial construction without touching the success path. Taught in Chapter 24: Zig
- Error return trace: a record, kept by the Zig runtime, of where an error was created and every frame it was returned through, so a failure can be traced without exceptions or stack unwinding. Taught in Chapter 24: Zig
- Error union: a Zig type
E!Tthat holds either an error from the setEor a value of typeT;trypropagates the error andcatchhandles it. Taught in Chapter 24: Zig - Errors as values: reporting failure by returning an ordinary error value alongside the result, as Go’s
errorinterface does, instead of throwing an exception; every failure path is then an explicit check such asif err != nil. Taught in Chapter 20: Go - Escape analysis: a compiler pass that keeps a value on the stack unless a reference to it can outlive the function, in which case the value is moved to the heap; Go and the JVM use it to reduce garbage-collector work. Taught in Chapter 20: Go
- event loop: the single-threaded scheduler that runs ready coroutines and wakes them when their sockets or timers are ready. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency
- Exchange argument: a proof that a greedy algorithm is optimal, made by taking any optimal solution that differs from the greedy one, swapping in the greedy choice, and showing the result is no worse. Taught in Chapter 10: Greedy algorithms
- executor: the part of the runtime that polls ready tasks on a pool of worker threads. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper
- Exhaustive pattern matching: a
matchthat the compiler checks covers every variant of a type, so adding a variant turns each place that does not handle it into a compile error. Taught in Chapter 21: Rust - exit status: the integer from 0 to 255 a process reports when it ends; 0 means success. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- Explicit allocator: the Zig convention that every function that allocates takes an allocator as a parameter, so memory cost is visible at the call site and the strategy (arena, pool, leak-detecting test allocator) can change without changing the code. Taught in Chapter 24: Zig
- exponential backoff: waiting after failed attempt before trying again. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency
- Expression template: a type that represents an unevaluated expression, evaluated later in one pass. Taught in 19.5 Expression templates
- Failure atomicity: the property that a failed operation leaves the structure exactly as it was. Taught in 15.1 A growable array
- False positive: a non-member whose probes all land on bits set by other items. Taught in 15.8 A Bloom filter
- Fast and slow pointers: two pointers that move through a sequence at different speeds, usually one and two steps; the slow one is at the midpoint when the fast one reaches the end, and the two meet if the sequence contains a cycle. Taught in Chapter 4: Two pointers and sliding window
- Fenwick tree / binary indexed tree (BIT): an array-based structure for prefix sums with point updates and prefix queries, smaller and simpler than a segment tree. Taught in Chapter 16: Competitive Programming
- field number: the integer that identifies a field on the wire; it must never change or be reused. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- Find-or-insert: the operation that returns an existing entry for a key or creates one. Taught in 18.9 String interning
- Fingerprint (): the low 7 bits of the mixed hash, used to reject slots without reading their keys. Taught in 15.2 A Swiss table
- Fixed-size sliding window: a window of exactly consecutive elements moved one step at a time, updating a running aggregate by adding the element that enters and removing the one that leaves, so all windows together cost . Taught in Chapter 4: Two pointers and sliding window
- Flexible array member: a trailing
data[]array in a struct, letting header and variable-size storage share one allocation. Taught in 18.8 Arena allocator - Flood fill: a DFS or BFS from one cell that marks every cell reachable through matching neighbors; starting one from each unvisited cell counts connected regions, such as the islands in a grid. Taught in Chapter 8: Graphs
- Floyd’s construction (heapify): building a heap in by sifting down every parent, last first. Taught in 15.6 A binary heap with lazy deletion
- Floyd’s cycle detection / tortoise and hare: detecting a cycle in a linked list by advancing one pointer one step and another two steps until they meet, then finding the cycle’s start by restarting one pointer at the head and advancing both one step at a time until they meet again. Taught in Chapter 6: Linked lists
- FNV-1a: a byte-at-a-time hash that XORs each byte in and then multiplies by a prime. Taught in 15.8 A Bloom filter
- For-comprehension: Scala syntax that desugars a sequence of generators into nested
flatMapcalls and a finalmap, giving sequential-looking code forOption,Future, and other monads. Taught in Chapter 25: Scala - Frequency counting: building a map from each value to the number of times it occurs in one pass, then answering questions about duplicates, anagrams, or the most common elements from that map. Taught in Chapter 3: Arrays and hashing
- Full expression: the outermost expression of a statement; temporaries live until it ends. Taught in 19.5 Expression templates
- Full slice expression:
a[low:high:max], which also sets the capacity of the resulting slice. Taught in 17.1 Predicting Go output - future: a value implementing
Future, which does nothing until polled and then returnsReadyorPending. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper - Fx hash: a fast rotate-xor-multiply hash whose strong bits are the high ones. Taught in 15.5 A Robin Hood hash map
- Generation counter: a per-slot counter, copied into handles, that makes old handles mismatch after the slot is reused. Taught in 15.6 A binary heap with lazy deletion
- Generator: a paused function frame that runs to the next
yieldon eachnextand is exhausted once its body finishes. Taught in 17.2 Predicting Python output - Geometric growth: multiplying the capacity by a constant factor when full, which makes appends amortized. Taught in 15.1 A growable array
- Geometric growth: growing capacity by a constant factor, which makes the total copying cost linear in the number of pushes. Taught in 18.1 Dynamic array
- Given instance: a Scala 3 value declared with
giventhat the compiler supplies automatically wherever a parameter of its type is required; it replaces implicits for type-class instances and derivation. Taught in Chapter 25: Scala - Global interpreter lock (GIL): CPython’s lock that lets only one thread execute Python bytecode at a time, so threads speed up I/O-bound work but not CPU-bound work; an experimental free-threaded build from 3.13 removes it. Taught in Chapter 22: Python
- goroutine: a function running concurrently, scheduled by the Go runtime. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- Goto-cleanup pattern: a C idiom in which every failure path jumps with
gototo labels at the end of the function that release resources in reverse order of acquisition, so each resource is freed exactly once on every exit path. Taught in Chapter 18: C - graceful shutdown: stop accepting, let in-flight work finish within a bound, then exit 0. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper
- Gradual typing: a type system in which static type annotations are optional and unannotated code stays dynamically typed; Python’s interpreter ignores annotations, and checkers such as mypy and pyright enforce them. Taught in Chapter 22: Python
- Granule (): the run length in tokens at which labels are compared and split; one KV block. Taught in 15.7 A radix tree over token ids
- Greedy algorithm: an algorithm that commits at each step to the choice that looks best now and never reconsiders it; it is correct only when the problem has the greedy-choice property. Taught in Chapter 10: Greedy algorithms
- Greedy-choice property: the property that some optimal solution begins with the locally best choice, so committing to that choice never rules out an optimum; it is what separates greedy problems from dynamic programming ones. Taught in Chapter 10: Greedy algorithms
- half-open window: a time range
[since, until)that includes its start and excludes its end. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - Handle: the stable pointer (
const Interned *) the table returns for a string. Taught in 18.9 String interning - Hash flooding: a denial-of-service attack that sends keys chosen to collide, turning O(1) operations into O(n). Taught in 18.2 Hash map with open addressing
- header: a case-insensitive name, a colon, and a value in an HTTP message head. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up
- Heap property: in a min-heap, every parent’s priority is less than or equal to its children’s. Taught in 18.4 Binary heap
- Heap sort: repeatedly moving the root to the end of a shrinking heap to sort in place. Taught in 15.4 Heap top-k in C
- Heapify (Floyd’s method): building a heap in O(n) by sifting down every internal node from the bottom up. Taught in 18.4 Binary heap
- Helm chart: a directory of templated Kubernetes YAML plus default values; installing it creates a release. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Higher-kinded type: a type parameterized by a type constructor rather than a type, such as
F[_], which lets one piece of code abstract over containers likeList,Option, andFuture. Taught in Chapter 25: Scala - Hole: an array index with no property at all, distinct from a property holding
undefined. Taught in 17.4 Predicting TypeScript output - Home group: the group of 16 slots where a key’s probe starts, chosen by . Taught in 15.2 A Swiss table
- Huffman code table: the dictionary from each character to its bit string, read off the Huffman tree; the decoder needs it, or the tree, to turn the bit stream back into text. Taught in 10.1 Huffman coding
- Huffman coding: an optimal prefix code built greedily by repeatedly merging the two least frequent symbols or subtrees with a min-heap, so the rarest symbols get the longest codewords; it takes for symbols. Taught in Chapter 10: Greedy algorithms
- Huffman tree: the binary tree Huffman’s algorithm builds, with each character at a leaf; a character’s code is its path from the root, 0 for a left branch and 1 for a right one, so frequent characters sit near the root and get short codes. Taught in 10.1 Huffman coding
- HyperLogLog (HLL): a cardinality estimator that hashes each element and records the most leading zeros seen in each of many buckets, then combines the buckets with a harmonic mean; it counts billions of distinct items to within about 2% in about 1.5 KB. Taught in Chapter 14: Probabilistic data structures
- Idempotent free: a release function that is safe to call twice because it returns the object to its initial empty state. Taught in 18.1 Dynamic array
- Identity: whether two names refer to the same object, tested with
is. Taught in 17.2 Predicting Python output - IEEE 754 double: the 64-bit floating-point format of every JavaScript
number, exact for integers up to 2^53. Taught in 17.4 Predicting TypeScript output - image: a stack of content-addressed filesystem layers plus a config that says how to start the process. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Implicit graph: a graph whose nodes and edges are computed on demand rather than stored, such as grid cells and their four neighbors or words that differ by one letter; it needs no extra space for edges. Taught in Chapter 8: Graphs
- In-degree: the number of edges entering a vertex, counting parallel edges separately. Taught in 18.6 Graph as an adjacency list
- In-order traversal: visiting a binary tree’s left subtree, then the node, then the right subtree; on a binary search tree it produces the values in sorted order. Taught in Chapter 7: Trees
- In-place list reversal: reversing a linked list in one pass with extra space by pointing each node’s
nextback at its predecessor, saving the originalnextfirst so the rest of the list is not lost. Taught in Chapter 6: Linked lists - Incremental parser: a parser that accepts input in arbitrary chunks and resumes where the previous chunk ended. Taught in 18.10 HTTP request parser
- index: a sorted B-tree copy of chosen columns that lets a query search instead of scan. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates
- Index marking: using an array’s own indices as a hash table when its values lie in , for example by negating the entry at index to record that was seen; it gives time with extra space. Taught in Chapter 3: Arrays and hashing
- Input iterator: a single-pass iterator whose copies do not independently preserve position. Taught in 19.6 Coroutine generator
- Input range: a range that can be traversed once, front to back. Taught in 19.8 Graph with concepts
- interface: a method set that any type with those methods satisfies implicitly. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- Interface value: a pair of dynamic type and dynamic value, nil only when both halves are nil. Taught in 17.1 Predicting Go output
- Interval DP: dynamic programming over contiguous ranges that tries every split point and fills the table in order of increasing interval length, typically in ; used for matrix-chain multiplication and Burst Balloons. Taught in Chapter 9: Dynamic programming
- Interval scheduling: selecting the most non-overlapping intervals, solved greedily by sorting on end time and taking each interval that starts no earlier than the last chosen one ends. Taught in Chapter 10: Greedy algorithms
- Intrusive free list: a list of free blocks whose links are stored inside the free blocks themselves. Taught in 19.9 Memory pool allocator
- Intrusive list: a linked list whose link fields live inside the elements, so linking needs no allocation. Taught in 15.3 An intrusive list and an LRU
- Intrusive list: a list whose link fields are embedded in the elements themselves rather than in separately allocated nodes. Taught in 18.3 Intrusive linked list
- Inversion count: the number of pairs with , computed in during merge sort’s merge by adding the number of remaining left-half elements each time a right-half element is taken first. Taught in Chapter 13: Recursion and divide-and-conquer
- Involution: a function that is its own inverse, such as on
int. Taught in 18.4 Binary heap
- Java record: a class declared as
record Point(int x, int y), an immutable data carrier for which the compiler generates the constructor, accessors,equals, andhashCode. Taught in Chapter 26: Java
- k-sum reduction: solving 3Sum, 4Sum, and their relatives by sorting, fixing elements in nested loops, and running a two-pointer sweep on the rest while skipping repeated values; it brings 3Sum from to . Taught in Chapter 4: Two pointers and sliding window
- k-way merge: merging sorted lists by keeping their current heads in a min-heap of size and repeatedly taking the smallest, in time for elements in total. Taught in Chapter 6: Linked lists
- Kadane’s algorithm: the maximum-subarray algorithm that tracks the best sum of a subarray ending at the current position, either extending the previous one or starting fresh, along with the best sum seen overall. Taught in Chapter 9: Dynamic programming
- Kahn’s algorithm: topological sort by repeatedly emitting vertices whose in-degree has dropped to zero. Taught in 18.6 Graph as an adjacency list
- Kernighan’s algorithm: counting the set bits (the popcount) of an integer by repeatedly clearing the lowest one with
n &= n - 1, in time proportional to the number of set bits. Taught in Chapter 12: Math and bit manipulation - kind: a tool that runs each Kubernetes node as a Docker container. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Knuth-Morris-Pratt algorithm (KMP): string matching in that uses a failure function over the pattern to know, after a mismatch, how far the pattern can shift without re-reading text. Taught in Chapter 16: Competitive Programming
- Ladder: a preallocated array indexed by price tick, with a pointer to the best level. Taught in Chapter 27: Case Study: Order Book Matching
- Lazy adapter: an iterator method such as
mapthat builds a wrapper and does no work until a consumer callsnext. Taught in 17.3 Predicting Rust output - Lazy deletion: marking an item dead and discarding it only when it reaches the root. Taught in 15.6 A binary heap with lazy deletion
- Lazy deletion: leaving outdated entries in a priority queue and discarding them when popped. Taught in 19.8 Graph with concepts
- Lazy deletion: leaving stale entries in a heap and discarding them when they reach the top. Taught in Chapter 27: Case Study: Order Book Matching
- Lazy evaluation: deferring computation until its result is needed. Taught in 19.5 Expression templates
- Lazy propagation: deferring range updates in a segment tree by storing pending changes at internal nodes and pushing them to the children only when a later operation descends through, which makes range updates . Taught in Chapter 16: Competitive Programming
- Left-boundary binary search: the binary search over a half-open interval
[left, right)that returns the first index where a condition holds, or the length if it never does, by never discarding amidthat satisfies the condition. Taught in Chapter 5: Binary search - Level-order traversal: visiting a tree level by level with a queue, reading the queue’s length at the start of each round to know how many nodes belong to the current level; it is breadth-first search on a tree. Taught in Chapter 7: Trees
- Linear probing: on a collision, trying the next slot, wrapping at the end. Taught in 15.5 A Robin Hood hash map
- Linear probing: on collision, trying the next slot, then the next, wrapping at the end. Taught in 18.2 Hash map with open addressing
- linkage: whether a name is visible outside its translation unit (external) or only inside it (internal,
static). Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain - Load factor: the fraction of slots that are not empty; here it counts tombstones as well as live entries. Taught in 18.2 Hash map with open addressing
- Load factor (): entries divided by slots; here kept at or below 7/8. Taught in 15.5 A Robin Hood hash map
- Lock count: the number of locks pinning a node, counting locks on its descendants. Taught in 15.7 A radix tree over token ids
- Lost wake-up: a notification that arrives between a waiter’s predicate check and its sleep, and is therefore missed. Taught in 19.4 Thread-safe queue
lower_bound/upper_bound: binary searches for the first position not less than, or the first position greater than, a key. Taught in 18.5 Merge sort, buffered and in place- Lowest common ancestor (LCA): the deepest node that has both of two given nodes as descendants, counting a node as its own descendant; found by searching both subtrees in a general binary tree, or by following the values left or right in a BST. Taught in Chapter 7: Trees
- Lowest set bit: the least significant 1 bit of an integer;
x & -xisolates it andx & (x - 1)clears it, both because negation in two’s complement flips every bit above it. Taught in Chapter 12: Math and bit manipulation - LRU (least recently used): an eviction policy that reclaims the element whose last use is oldest. Taught in 15.3 An intrusive list and an LRU
- Mapped type: a type that transforms every property of another type, such as the built-in
Partial<T>, which makes each property optional. Taught in Chapter 23: TypeScript - Mark: a saved (block, offset) position that the arena can later rewind to. Taught in 18.8 Arena allocator
max_align_t: the standard type whose alignment is at least as strict as every scalar type’s. Taught in 18.8 Arena allocator- Memoization / top-down DP: caching a recursive function’s results by its arguments so each subproblem is solved once; the recursive way to implement dynamic programming. Taught in Chapter 9: Dynamic programming
- Merge: combining two sorted runs into one sorted run in linear time. Taught in 18.5 Merge sort, buffered and in place
- Microtask queue: the queue of promise reactions and
awaitcontinuations, drained completely before the next macrotask. Taught in 17.4 Predicting TypeScript output - Min-heap under : a heap whose root is the worst entry, so it serves as the admission threshold. Taught in 15.4 Heap top-k in C
- module: a directory tree with a
go.modfile, containing packages under one module path. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing - Monomorphization: compiling generics by emitting a specialized copy per concrete type. Taught in 2.4 Generics at runtime and language comparison
- Monotonic predicate: a condition over an ordered search space that flips from false to true (or true to false) exactly once; binary search finds the flip point in evaluations. Taught in Chapter 5: Binary search
- move: transfer of ownership by assignment or by passing a value, after which the old variable is unusable. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP
- Move semantics: transferring the resources of an object that is about to be discarded (an rvalue) to a new owner by taking its pointers instead of copying what they point at;
std::movecasts a value to an rvalue to request it. Taught in Chapter 19: C++ - Move-only type: a type that can be moved but not copied, so ownership can transfer but never duplicate. Taught in 19.2 UniquePtr
- MRO: the method resolution order, the C3-linearised list of classes that attribute reads and
super()follow. Taught in 17.2 Predicting Python output - Multi-source BFS: a breadth-first search whose queue starts with every source at once, so the distance it assigns each node is the distance to the nearest source. Taught in Chapter 8: Graphs
- multi-stage build: a Dockerfile with several
FROMstages, where only the last stage ships. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind mutable: a member that may be modified insideconstmember functions because it is not part of observable state. Taught in 19.4 Thread-safe queue
- Nagle’s algorithm: a TCP rule that delays small segments to merge them, disabled with
TCP_NODELAY. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up - named parameter: a placeholder such as
:tenantwhose value is bound separately and is always data. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - namespace: a kernel-provided private view of one kind of resource (filesystem, processes, network, hostname, user ids) for a process. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- nearest-rank percentile: the value at rank of the sorted values. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates
- Newtype pattern: wrapping an existing type in a single-field struct, such as
struct Miles(f64), so the compiler tells apart values with the same representation but different meanings, at no run-time cost. Taught in Chapter 21: Rust - No hidden control flow: Zig’s design rule that code does only what it visibly says: no operator overloading, no hidden allocations, and no exceptions, so every call, allocation, and early return appears in the source. Taught in Chapter 24: Zig
- Non-type template parameter: a template parameter that is a value, such as
std::size_t Rows, rather than a type. Taught in 19.3 Compile-time matrix - Number-theoretic transform (NTT): the fast Fourier transform carried out in arithmetic modulo a suitable prime, which multiplies integer polynomials in with exact results and no rounding. Taught in Chapter 16: Competitive Programming
- Occurs check: the test that a type variable does not appear inside the type it is being bound to, which keeps types finite. Taught in 2.4 Generics at runtime and language comparison
offsetof: the standard macro giving a member’s byte offset within its struct. Taught in 18.3 Intrusive linked list- Opaque pointer: a pointer to a struct that a header only declares (
struct Foo;) and the.cfile defines, so callers can hold and pass it but cannot reach its fields; C’s main tool for encapsulation. Taught in Chapter 18: C - Opaque type: a Scala 3 type alias whose underlying representation is visible only where it is defined, giving a distinct type with no run-time cost; a newtype without a wrapper. Taught in Chapter 25: Scala
- Open addressing: storing every entry in the slot array itself, resolving collisions by probing other slots. Taught in 15.5 A Robin Hood hash map
- Open addressing: storing every entry in the table array itself and resolving collisions by probing other slots. Taught in 18.2 Hash map with open addressing
- Option type: a type that holds either a value or nothing, such as Rust’s
Option<T>, used instead of null so the compiler forces every use to handle absence. Taught in Chapter 21: Rust - orphan: a child process that outlives the parent that started it. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- owner: the single variable responsible for a value; when it goes out of scope, the value is dropped. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP
- ownership: the rule that exactly one piece of code frees each allocated block, exactly once. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- package: one directory of
.gofiles sharing apackagename; capitalized names are exported. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing - padding: unused bytes the compiler inserts so each struct field is aligned. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- panic: an abort of the current thread, meant for bugs rather than bad input. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP
- Parametric polymorphism: one implementation that works uniformly at every type because it cannot inspect the type. Taught in 2.4 Generics at runtime and language comparison
- Parser differential: any input that two conforming-looking parsers interpret differently. Taught in 18.10 HTTP request parser
- Pascal’s rule: the identity , which builds Pascal’s triangle and gives a DP for binomial coefficients without large factorials. Taught in Chapter 12: Math and bit manipulation
- Path compression: a union-find optimization in which
findpoints the nodes it passes closer to, or directly at, their root, flattening the trees so later finds are nearly constant time. Taught in Chapter 8: Graphs - Path-dependent type: a type that belongs to a particular value, written
x.T, so the member types of two different instances are distinct and cannot be mixed. Taught in Chapter 25: Scala - Patience sorting: an method for the longest increasing subsequence that keeps the smallest possible tail for each subsequence length and binary searches where each new value belongs; the number of piles is the length of the subsequence. Taught in Chapter 5: Binary search
- pattern rule: a make rule such as
%.o: %.cthat says how to build any file of one kind from another. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes - Per-iteration loop variable: since Go 1.22, each variable declared in a
forheader is a new variable on every iteration. Taught in 17.1 Predicting Go output - phony target: a make target that names an action rather than a file and always runs. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- pid 1: the first process in a pid namespace, to which the kernel does not apply
SIGTERM’s default action. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind - Placement new: constructing an object at a given address without allocating. Taught in 19.7 Function: type erasure with a small buffer
- pointer: an address plus the type of the object at that address. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- Pointer stability: the guarantee that an address handed out remains valid as the container grows. Taught in 18.9 String interning
- Pointer-movement invariant: the argument, stated before writing a two-pointer or sliding-window loop, that moving a given pointer cannot skip a valid answer; it is what makes such a solution correct. Taught in Chapter 4: Two pointers and sliding window
- Pool allocator: an allocator that serves fixed-size blocks from a free list. Taught in 19.9 Memory pool allocator
- pragma: a SQLite setting, stored either in the file or only on the connection that ran it. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates
- Predicate loop: re-testing the awaited condition under the lock after every wake-up. Taught in 18.7 Thread pool
- Predicate wait:
cv.wait(lock, pred), which loops untilpred()is true. Taught in 19.4 Thread-safe queue - Prefix code: a code in which no codeword is a prefix of another, so a bit stream decodes left to right without separators; any prefix code is a binary tree with the symbols at its leaves. Taught in Chapter 10: Greedy algorithms
- Prefix sum: the running total of an array up to each position, so any subarray sum is the difference of two prefix sums; with a hash map of the prefix sums seen so far, it counts the subarrays that sum to in . Taught in Chapter 3: Arrays and hashing
- Price level: the set of resting orders on one side at one price, kept in arrival order. Taught in Chapter 27: Case Study: Order Book Matching
- Price-time priority: matching the best price first and, within a price, the oldest order first. Taught in Chapter 27: Case Study: Order Book Matching
- Principal type: the most general type of a term, of which all its other types are instances. Taught in 2.4 Generics at runtime and language comparison
- Probabilistic data structure: a structure that answers membership, frequency, or cardinality queries approximately, with a bounded error probability, in far less space than an exact structure would need. Taught in Chapter 14: Probabilistic data structures
- Probe run: the contiguous sequence of occupied slots a lookup walks from a key’s home slot. Taught in 18.2 Hash map with open addressing
- Promise type: the nested
promise_typewhose members the compiler calls at fixed points in a coroutine’s life. Taught in 19.6 Coroutine generator - Prototypal inheritance: JavaScript’s object model, in which each object links to a prototype object and a property lookup that misses on the object walks up that chain; classes are syntax over it. Taught in Chapter 23: TypeScript
- Pruning: abandoning a branch of a search as soon as it is known not to lead to a valid or better solution, using sorted input, bounds, duplicate skipping, or constraint checks; it is what makes exponential searches fast on real inputs. Taught in Chapter 11: Backtracking
- Quickselect: expected-linear selection of the -th element by partitioning, which reorders its input. Taught in 15.4 Heap top-k in C
- Radix tree: a trie whose single-child chains are merged into labelled edges. Taught in 15.7 A radix tree over token ids
- RAII: Resource Acquisition Is Initialization; tying a resource’s release to an object’s destructor. Taught in 19.2 UniquePtr
- Raw storage: allocated memory in which no object has yet been constructed. Taught in 19.1 Vector
Rc<T>: a reference-counted pointer giving shared ownership, freed when the strong count reaches zero. Taught in 17.3 Predicting Rust output- reactor: the part of the runtime that asks the OS which sockets are ready and wakes the waiting tasks. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper
- readiness and liveness probes: periodic checks that respectively remove a Pod from endpoints and restart a stuck container. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Rebinding: converting an allocator for
Tinto one for another type, such as a container’s internal node. Taught in 19.9 Memory pool allocator - recursive-descent parser: a parser with one function per grammar rule, chosen by lookahead. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up
- Reference counting: memory management in which each object counts the references to it and is freed when the count drops to zero; CPython uses it, backed by a cycle-detecting garbage collector for objects that refer to each other. Taught in Chapter 22: Python
release/reset: give up ownership without deleting, versus delete the owned object and adopt another. Taught in 19.2 UniquePtr- Relocation: moving an object to a new address, done here by move construction plus destruction of the source. Taught in 19.7 Function: type erasure with a small buffer
- Repeated squaring: computing with O(log n) multiplications by following the binary digits of . Taught in 19.3 Compile-time matrix
- Request smuggling: an attack that exploits two parsers disagreeing about message boundaries to hide one request inside another. Taught in 18.10 HTTP request parser
requiresclause: a constraint that removes a declaration when its condition is false. Taught in 19.3 Compile-time matrix- Requires expression: the
requires (...) { ... }syntax listing expressions a type must support. Taught in 19.8 Graph with concepts - Reserve: a one-time allocation of a known final capacity, which never shrinks. Taught in 15.1 A growable array
Result: the enumOk(T)orErr(E)that a fallible function returns. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP- retryable failure: a failure a later attempt may not see, such as a 5xx, 429, cut connection, or timeout. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency
- reverse proxy: a server that forwards each request to an upstream and relays the response. Taught in 1.6 Go: packages, interfaces, goroutines, channels, context, net/http, testing
- Ring buffer: a fixed array used as a FIFO queue with head and tail indices that wrap. Taught in 18.7 Thread pool
- Robin Hood insertion: a carried entry takes the slot of any resident with smaller displacement. Taught in 15.5 A Robin Hood hash map
- Robustness principle: “be liberal in what you accept”; safe only where every reading produces the same message. Taught in 18.10 HTTP request parser
- Rolling array: keeping only the last row or last few values of a DP table when each entry depends only on recent ones, which removes a dimension from the space cost. Taught in Chapter 9: Dynamic programming
- Rotated sorted array: a sorted array shifted cyclically, such as
[4, 5, 6, 7, 0, 1, 2]; around any midpoint one half is still sorted, which lets binary search decide which half can contain the target. Taught in Chapter 5: Binary search - Rotation: cyclically shifting a segment so
[A B]becomes[B A], done in place with three reversals. Taught in 18.5 Merge sort, buffered and in place - Rule of five: a type that manages a resource defines (or deletes) the copy and move constructors, copy and move assignment, and destructor together. Taught in 19.1 Vector
- Run: a contiguous, already-sorted segment of the array. Taught in 18.5 Merge sort, buffered and in place
- Rune: a Unicode code point, the unit yielded by
for rangeover a string. Taught in 17.1 Predicting Go output
- Same-size rebuild: a rehash that drops tombstones without growing, because the live keys still fit. Taught in 15.2 A Swiss table
- Saturating and wrapping arithmetic: explicit methods that clamp to the type’s bounds or wrap modulo its width. Taught in 17.3 Predicting Rust output
- Sealed class / sealed interface: a Java class or interface that lists the only types allowed to extend it, so a pattern-matching
switchover it can be checked for exhaustiveness; with records, Java’s way to write algebraic data types. Taught in Chapter 26: Java - Sealed trait: a Scala trait whose subtypes must all be defined in the same file, so the compiler knows every case and checks pattern matches for exhaustiveness; with case classes it encodes algebraic data types. Taught in Chapter 25: Scala
- Segment tree: a binary tree over array ranges in which each node stores an aggregate, such as the sum or minimum, of its range; it supports point updates and range queries in after an build. Taught in Chapter 16: Competitive Programming
- semaphore: a counter of permits that bounds how many coroutines are inside a section at once. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency
- semaphore permit: a value representing one slot; holding it holds the slot, dropping it frees it. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper
- Send and Sync: Rust’s marker traits for thread safety: a
Sendtype may be moved to another thread and aSynctype may be shared between threads by reference, so the compiler rejects code that could race. Taught in Chapter 21: Rust - Sentinel: a permanent dummy node in a circular list that makes every real node have real neighbours. Taught in 15.3 An intrusive list and an LRU
- Sentinel: a dummy node that is never an element, used so that every real node always has neighbours. Taught in 18.3 Intrusive linked list
- Server-Sent Events: a
text/event-streamresponse whose body isdata:lines grouped into events by blank lines. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up - Service: a stable name and virtual IP for the ready Pods whose labels match its selector. Taught in 1.7 Containers and Kubernetes: images, layers, Pods, Deployments, Services, Helm, kind
- Shadowing: introducing a new binding with an existing name, hiding the old one until the scope ends. Taught in 17.3 Predicting Rust output
- Shallow copy: a new outer container holding the same element references. Taught in 17.2 Predicting Python output
- Sift up / sift down: repairs of the heap property after appending at the end or replacing the root. Taught in 15.4 Heap top-k in C
- Sift up / sift down: the swaps that restore the heap property after a push at a leaf or a replacement at the root. Taught in 15.6 A binary heap with lazy deletion
- Sift up / sift down: the repairs that move one element toward the root or the leaves until the heap property holds again. Taught in 18.4 Binary heap
- signal: an asynchronous message from the kernel to a process, such as SIGTERM or SIGKILL. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- Skip list: a sorted multi-level linked list in which each element is promoted to the next level up with probability ; a search moves right, then drops down a level, giving expected search, insertion, and deletion without rebalancing. Taught in Chapter 14: Probabilistic data structures
- Slice header: the (pointer, length, capacity) triple that views a backing array. Taught in 17.1 Predicting Go output
- Sliding window: a contiguous range of an array or string whose two ends move only forward, so each element enters and leaves once and the whole scan is . Taught in Chapter 4: Two pointers and sliding window
- Small buffer optimisation (SBO): storing small objects inside the owning object to avoid a heap allocation. Taught in 19.7 Function: type erasure with a small buffer
- Smart pointer: a class that owns a heap object and frees it in its destructor, applying RAII to memory;
std::unique_ptrhas exactly one owner andstd::shared_ptrcounts shared owners. Taught in Chapter 19: C++ - Soundness: the guarantee that well-typed programs do not get stuck, proved as progress plus preservation. Taught in 2.4 Generics at runtime and language comparison
- Sparse table: precomputed answers for every range whose length is a power of two, built in , that answer idempotent range queries such as range minimum in on a static array. Taught in Chapter 16: Competitive Programming
- Splice: moving a whole run of nodes from one list to another by rewriting only the boundary pointers. Taught in 18.3 Intrusive linked list
- Split: inserting a middle node so that a match ending inside an edge ends at a node. Taught in 15.7 A radix tree over token ids
- SplitMix64 finalizer (mix64): a bijection on 64-bit words that mixes every input bit into every output bit. Taught in 15.8 A Bloom filter
- Sprague-Grundy theorem: every impartial game is equivalent to a Nim heap whose size is the game’s Grundy value, so a sum of games is a win for the player to move exactly when the XOR of the Grundy values is nonzero. Taught in Chapter 16: Competitive Programming
- Spurious wake-up: a return from a condition-variable wait with no corresponding signal, or after another thread consumed the change. Taught in 18.7 Thread pool
- Stable heap: one that pops equal items in push order, here via a sequence number. Taught in 15.6 A binary heap with lazy deletion
- Stable sort: a sort that keeps equal elements in their input order; heapsort is not one. Taught in 18.4 Binary heap
- Stable sort: a sort that keeps elements with equal keys in their input order. Taught in 18.5 Merge sort, buffered and in place
- stale lock: a lock file left by a process that died without cleaning up. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- Stamp: the clock value of the last walk through a node, used to order the LRU list. Taught in 15.7 A radix tree over token ids
- State-machine DP: dynamic programming that keeps one value per discrete state at each position, such as holding, just sold, or resting in stock-trading problems, and updates them together from the previous position’s values. Taught in Chapter 9: Dynamic programming
- status code: the three-digit number in a response’s status line, whose first digit is its class. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up
- status code: the gRPC result in the trailers, telling the caller what kind of failure happened. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
std::construct_at/std::destroy_at: start and end the lifetime of one object at a given address. Taught in 19.1 Vectorstd::move_if_noexcept: yields an rvalue if the move constructor cannot throw (or the type is not copyable), and a const lvalue otherwise. Taught in 19.1 Vectorstd::unique_lock: an RAII lock that can be unlocked early and is required bycondition_variable::wait. Taught in 19.4 Thread-safe queue- Sticky error state: an error that, once entered, every later call reports, because the stream cannot be safely resynchronised. Taught in 18.10 HTTP request parser
- stride: the number of bytes to move along an axis to reach the next index on it. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- String interning: keeping one canonical copy of each distinct string so equality becomes pointer comparison. Taught in 18.9 String interning
- Strong exception guarantee: if an operation throws, the object is left exactly as it was before. Taught in 19.1 Vector
- Structural typing: type compatibility decided by shape: a value fits a type when it has the required members, whatever it was declared as; TypeScript’s types and Go’s interfaces both work this way. Taught in Chapter 23: TypeScript
- Structured concurrency: scoping a group of concurrent tasks to one block, so the block does not exit until all of them have finished and a failure in one cancels the rest. Taught in Chapter 26: Java
- Subsumption: the rule that a concept defined in terms of another is more specific, used to order overloads. Taught in 19.8 Graph with concepts
- Suffix array: the starting positions of a string’s suffixes in sorted order, built in ; with its LCP (longest common prefix) array it answers substring queries. Taught in Chapter 16: Competitive Programming
- surrogate pair: two
\uXXXXescapes, a high and a low surrogate, that together spell a character above U+FFFF. Taught in 1.5 HTTP/1.1, JSON, and Server-Sent Events from the wire up - Suspend point: a place where the coroutine pauses; initial and final suspend are the two implicit ones. Taught in 19.6 Coroutine generator
- SWAR: SIMD within a register; testing all bytes of a 64-bit word with a few integer operations. Taught in 15.2 A Swiss table
- Symmetry breaking: fixing a choice, such as the first element or the first color, so a search does not explore solutions that are mirror images or relabelings of ones it has already found. Taught in Chapter 11: Backtracking
- Table-driven test: a test written as a slice of input and expected-output cases run by one loop, so adding a case is one line; the standard style of Go’s
testingpackage. Taught in Chapter 20: Go - tag: the varint that starts each record, combining field number and wire type. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- task: a coroutine scheduled on the loop with
asyncio.create_task, whose result can be awaited later. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency - task: a future handed to the executor with
tokio::spawn, scheduled independently on the worker threads. Taught in 1.9 Async Rust and tokio: futures, tasks, channels, cancellation, hyper - TaskGroup: a structured block that waits for all its tasks and cancels the rest when one fails. Taught in 1.8 Python asyncio: event loop, tasks, cancellation, bounded concurrency
- Template literal type: a string type built by interpolating other types into a template, so the compiler can check that strings follow a pattern such as an event name or a route. Taught in Chapter 23: TypeScript
- Thread pool: a fixed set of long-lived worker threads that execute tasks taken from a shared queue. Taught in 18.7 Thread pool
TL_CONTAINER_OF: a macro that recovers the enclosing struct from a pointer to one of its members by subtracting the member’s offset. Taught in 15.3 An intrusive list and an LRU- Tombstone: a DELETED control byte that a probe must walk past. Taught in 15.2 A Swiss table
- Tombstone: a marker left by deletion that lookups skip over and inserts may reuse. Taught in 18.2 Hash map with open addressing
- Top-down DFS: a tree recursion that passes state, such as a running path sum, from parent to children as an argument (pre-order) and processes it at the leaves; it fits problems where information flows down from the root. Taught in Chapter 7: Trees
- Topological order: an ordering of a DAG’s vertices in which every edge points forward. Taught in 18.6 Graph as an adjacency list
- Total order: an order in which any two distinct elements compare one way or the other; here, by value and then by index. Taught in 15.4 Heap top-k in C
- Touch: moving a node to the most recent end, linking it if it was not linked. Taught in 15.3 An intrusive list and an LRU
- trait: a named set of methods a type promises to implement. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP
- trap: a bash handler that replaces a signal’s default action with your commands. Taught in 1.2 Shell, git, make, processes: exit codes, signals, environment, pipes
- Tree DP: dynamic programming over a tree in which each subtree returns a small tuple of answers, such as the best total with and without its root, and the parent combines its children’s tuples; it solves House Robber III and maximum path sum in . Taught in Chapter 7: Trees
- Try-with-resources: a Java
tryform that closes everyAutoCloseableresource it declares when the block exits, normally or by exception, in reverse order of opening. Taught in Chapter 26: Java - Two pointers: a technique that walks two indices through an array, from opposite ends or in the same direction, so that each move provably skips only candidates that cannot be the answer; on sorted or monotonic data it turns an pair search into an sweep. Taught in Chapter 4: Two pointers and sliding window
- Two-queue method: building a Huffman tree from leaves sorted by weight without a heap: leaves wait in one queue, merged subtrees join a second, and each step merges the two smallest items found at the two fronts. Merged weights come out in non-decreasing order, so both queues stay sorted and the build after sorting is . Taught in 10.1 Huffman coding
- Type erasure: compiling generics to one copy whose type parameters vanish at runtime. Taught in 2.4 Generics at runtime and language comparison
- Type erasure: storing elements as raw bytes of a fixed size
elem, so one implementation serves every element type. Taught in 15.1 A growable array - Type erasure: the removal of all type annotations, interfaces, and assertions before the program runs. Taught in 17.4 Predicting TypeScript output
- Type erasure: hiding a concrete type behind a uniform interface so unrelated types can be stored as one type. Taught in 19.7 Function: type erasure with a small buffer
- Typing judgment: the statement , that expression has type in context . Taught in 2.4 Generics at runtime and language comparison
- Unbounded knapsack: the knapsack variant in which each item may be reused any number of times; with a single row of storage the capacity loop runs forwards, and Coin Change is an instance. Taught in Chapter 9: Dynamic programming
- unbroadcast: the adjoint of broadcasting, which sums a gradient back to the operand’s shape. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- undefined behavior: an operation the C standard gives no meaning to, which the compiler assumes never happens. Taught in 1.3 C: memory, pointers, structs, headers, and the C11 toolchain
- Unification: solving equations between types by finding the most general unifier. Taught in 2.4 Generics at runtime and language comparison
- Union: the bitwise OR of two filters with the same and . Taught in 15.8 A Bloom filter
- Union by rank: a union-find rule that attaches the root of the shallower tree under the root of the deeper one so the trees stay shallow; with path compression it gives nearly constant amortized time per operation. Taught in Chapter 8: Graphs
- Union-find / disjoint-set union (DSU): a forest that keeps elements in disjoint sets, with
findreturning a set’s root andunionmerging two sets; it answers “are these connected?” as edges arrive in nearly constant amortized time per operation. Taught in Chapter 8: Graphs - unknown fields: records a reader does not recognize, kept by generated code and written back on re-encode. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- Unsafe Rust: code inside an
unsafeblock or function, where the compiler permits raw-pointer dereferences and other operations it cannot check, and the programmer must uphold the safety rules by hand. Taught in Chapter 21: Rust - Unsigned right shift: JavaScript’s
>>>, which shifts in zeros and reads the result as an unsigned 32-bit integer, unlike>>, which copies the sign bit into the vacated positions. Taught in Chapter 12: Math and bit manipulation - upsert: an
INSERT ... ON CONFLICT ... DO UPDATEthat inserts a row or updates the existing one. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - uv.lock: the file that pins the exact version and hash of every package in a uv project. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- Value restriction: ML’s rule that only syntactic values are generalized, keeping inference sound with mutable references. Taught in 2.4 Generics at runtime and language comparison
- Variable-size sliding window: a window over a contiguous subarray that grows on the right every step and shrinks on the left while a condition fails (for “longest”) or holds (for “shortest”); each element enters and leaves once, so the scan is . Taught in Chapter 4: Two pointers and sliding window
- Variance: how subtyping on a type argument lifts to the constructed type: covariant, contravariant, or invariant. Taught in 2.4 Generics at runtime and language comparison
- varint: an unsigned integer written 7 bits per byte, least significant group first, with a continuation bit. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- view: a new array object with its own metadata over an existing buffer. Taught in 1.1 Python and numpy: arrays, dtypes, broadcasting, views vs copies, uv projects
- Virtual node (vnode): one of a node’s many positions on the ring, used to even out arc shares. Taught in 15.9 A consistent hash ring with bounded loads
- Virtual thread: a lightweight Java thread (Java 21 and later) that the JVM schedules onto a few platform threads, cheap enough that blocking I/O code can use one thread per request. Taught in Chapter 26: Java
- Vtable: a table of function pointers used for dynamic dispatch, here written by hand. Taught in 19.7 Function: type erasure with a small buffer
- window function: a function computed per row over related rows without collapsing them, such as
ROW_NUMBER() OVER (...). Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates - wire type: the 3-bit code (VARINT, I64, LEN, I32) that tells a reader how many bytes a value occupies. Taught in 1.10 Protocol Buffers and gRPC: schema evolution, unary and streaming RPCs, stubs
- workspace: a set of Cargo packages sharing one
Cargo.lockand onetarget/directory. Taught in 1.4 Rust: ownership, traits, Result, cargo workspaces, std TCP - write-ahead logging (WAL): a journal mode in which commits append pages to a log, so readers and the single writer do not block each other. Taught in 1.11 SQL and SQLite: schema, transactions, WAL mode, indexes, aggregates
- XOR trick: using
a ^ a = 0,a ^ 0 = a, and the commutativity and associativity of XOR to cancel values that appear twice, so XOR-ing a whole collection leaves the one value that appears once. Taught in Chapter 12: Math and bit manipulation