2 modules · 33 topics

Machine coding

Build language fluency, recognize algorithmic patterns, and practice executable solutions.

A coding workbench with a laptop, a notebook, and a pencil.
Work the problem out, one small piece at a time.

Language fundamentals

Choose a language and work through its values, objects, concurrency, and runtime.

  1. 01

    Python

    Types, functions, objects, concurrency, and memory.

    20 lessons
  2. 02

    JavaScript

    Values, functions, prototypes, asynchronous execution, modules, and memory.

    14 lessons
  3. 03

    Go

    Values, interfaces, errors, goroutines, channels, and memory.

    13 lessons
  4. 04

    Java

    Types, collections, objects, generics, concurrency, and the JVM.

    14 lessons
  5. 05

    C++

    Values, ownership, lifetimes, templates, concurrency, and performance.

    13 lessons

Data structures & algorithms

How to organize data and choose an efficient algorithm.

  1. 01

    Arrays and linear scans

    Accumulators, indices, and loop invariants

  2. 02

    Strings and frequency maps

    Counting repeated values with dictionaries

  3. 03

    KMP string search

    Reuse matched prefixes instead of repeating comparisons

  4. 04

    Prefix sums

    Answer repeated range totals after one preprocessing pass

  5. 05

    Sliding windows with counts

    Maintain the longest contiguous range with at most k distinct values

  6. 06

    Sorting and two pointers

    Discard impossible pairs using sorted order

  7. 07

    Binary search on the answer

    Find the first feasible value of a monotone predicate

  8. 08

    Linked lists and node identity

    Remove nodes by changing links while retaining surviving objects

  9. 09

    Stacks and nested operations

    Validate last-in-first-out order with a stack

  10. 10

    Monotonic deques

    Keep only useful candidates for sliding-window maxima

  11. 11

    Heaps and k-way merge

    Merge sorted sequences through a small priority frontier

  12. 12

    Greedy interval scheduling

    Maximize the number of compatible intervals by earliest finish time

  13. 13

    Dynamic programming: minimum coins

    Reuse answers to smaller amounts when greedy choices fail

  14. 14

    0/1 knapsack

    Choose each item at most once under a capacity bound

  15. 15

    Edit distance

    Compare string prefixes with a two-dimensional recurrence

  16. 16

    Backtracking and pruning

    Explore partial assignments and undo choices that lead to failure

  17. 17

    Binary trees and level-order traversal

    Use a queue to visit nodes by depth

  18. 18

    Binary search trees

    Maintain ordered keys and find floor values

  19. 19

    Tries and prefix search

    Index shared prefixes for exact completion queries

  20. 20

    Graphs and breadth-first search

    Find shortest hop counts by exploring one layer at a time

  21. 21

    Topological sorting

    Order directed dependencies and detect cycles

  22. 22

    Dijkstra shortest paths

    Settle the cheapest frontier distance when all edge weights are nonnegative

  23. 23

    Bellman–Ford shortest paths

    Relax all edges and detect source-reachable negative cycles

  24. 24

    Floyd–Warshall all-pairs shortest paths

    Build a complete distance matrix by allowing intermediate vertices

  25. 25

    Kruskal and disjoint sets

    Build a minimum spanning tree by joining separate components

  26. 26

    Prim minimum spanning trees

    Grow a cheapest connection frontier directly from a dense matrix

  27. 27

    Fenwick trees

    Support point additions and range sums through binary-sized blocks

  28. 28

    Segment trees

    Combine interval summaries and repair them after point replacements