Skip to content

Liam's Learning Path

Everything we have covered, newest lesson first. Each lesson links to the pages that explain it, and to the problem set that practised it.

Timeline

Date Lesson What we covered Read Problem set
10-31 Hidden graphs: Two Buttons, directed BFS Setting up CLion and the code template; fixing Love Triangle (numbers 1 to n need size n + 1); turning Two Buttons into a graph where every number is a node; how far the nodes must go; directed edges with one push_back; when vis can be dropped (DAG); the magic lift problem Graph Traversal 8-Graph (6/11)
10-24 Rumor: DFS that returns a value; DSU again Turn the story into a graph and draw the sample; a DFS that gives back the cheapest person in a connected piece (and the BFS way); DSU rebuilt step by step: p[i] = i, connect the tops, find as a loop, then path compression; Rumor with DSU; at most 25 minutes of thinking per problem Graph Traversal
Disjoint Set Union
8-Graph (6/11)
10-17 Git and GitHub Git vs GitHub; git config, SSH key, git init, .gitignore, add / commit / push / pull; remote origin; branches, pull request and merge Git & GitHub —
10-10 BFS code; DFS with a stack Shortest distance in an unweighted graph: why DFS is a bad fit, dist array with INT_MAX, queue front / pop, the check dist[v] > dist[u] + 1 and its shorter form dist[v] == INT_MAX, answering queries; DFS with a stack instead of recursion Graph Traversal 8-Graph (6/11)
10-03 Adjacency list in depth; recursion; DFS code adj[u] is the list of neighbours of u, node names vs array positions, why size n + 1; list vs matrix before and after reading edges; recursive functions and lambdas with self; DFS on a list, on a matrix and as a lambda Terms & Representations
Graph Traversal
8-Graph (6/11)
09-26 Quiz review; DFS and BFS Went through the 20-question quiz; edge list with tuple / struct; memory of matrix (n^2) vs list (2m); DFS goes deep then backtracks, BFS goes level by level with a queue Terms & Representations
Graph Traversal
8-Graph (6/11)
09-19 Graph terms and representations Path, cycle, components, degree sum, tree, bipartite = no odd cycle, simple graph; adjacency list and matrix, weighted matrix; 20-question quiz Terms & Representations
Graph Basics
8-Graph (6/11)
09-13 Graph review homework Problem set 8: Badge (follow the edges), Forever Winter (degrees), Ice Skating (build the graph, count components) Graph Basics
Disjoint Set Union
8-Graph (6/11)
09-12 AIO 2026 Jump on Platforms, IGM, Discount Destinations, Sunday Drive II, Prime Minister, Mundane Square AIO 2026 —
08-23 DSU; AIO 2018 and 2025 Parent array, find with path compression, union; Street Construction to Detective; AIO 2025 set Disjoint Set Union
AIO 2018
AIO 2025
—
08-22 AIO 2019 Vases, RPS, Hiring Monks, Medusa's Snakes, Evading Capture (parity BFS), Lollipops II AIO 2019
BFS with Parity States
—
08-19 AIO 2020 Baubles, Cookies, Ghost Encounters, Tennis Robot, Ladybugs II, Beach Umbrellas AIO 2020
Binary Search
—
08-15 AIO 2021 Robot Vacuum, Art Class II, Melody, Social Distancing, Space Mission, Laser Cutter AIO 2021 —
08-10 DP quick start; AIO 2022 State / transition / base / order / answer; Fibonacci, stairs, LIS; Composing Pyramids DP Quick Start
AIO 2022
—
08-05 AIO 2023 and AIO 2024 TeleTrip, Distincto's Raffle, Making Bank, Shoptimality, Wheeling and Dealing, Lights; AIO 2024 set AIO 2023
AIO 2024
—
07-30 AIO 2025 Q6 proof; AIO 2024 practice Robot Writing claims 1-13; Javelin, Subbookkeeper, Shopping Spree, Backpacking, Tennis Robot II AIO 2025
AIO 2024
—
07-27 AIO 2025 Q5, Q6 Pairing Cards from both ends; Robot Writing layers AIO 2025 —
07-23 AIO 2025 Q4, Q5; AIO 2024 Q6 ORAC: training first, the mountain, binary search; Pairing Cards; Twin Rivers AIO 2025
AIO 2024
—
06-08 Directed graphs In-degree and out-degree; OJ contest Graph Basics (P1201-P1204) Graph Basics —
05-27 Adjacency matrix and list n^2 vs 2m numbers, neighbourhood, degree, sum of degrees = 2m Graph Basics —
05-13 What is a graph Vertices, edges, reading an edge list, finding the neighbours of one vertex Graph Basics —
05-10 Two pointers as add / del / check Templatising the window; longest sum <= 100 and shortest sum >= 100; greedy set assigned Two Pointers & Sliding Window
Greedy
6-TwoPointers (6/7)
7-Greedy (9/10)
04-29 Two pointers practice Prepend and Append, Balanced Team, Ternary String, Blinds (worked in class) Two Pointers & Sliding Window 6-TwoPointers (6/7)
04-15 Binary search vs two pointers When each applies; the commented two-pointer template Binary Search
Two Pointers & Sliding Window
5-BinarySearch (2/9)
04-12 Prefix sums + binary search pre[r] - pre[l-1]; largest valid r for each l; lambdas and captures Prefix Sum
Binary Search
5-BinarySearch (2/9)
04-05 USACO 2026 Contest 1; binary search Corner cases in Contest 1; the l <= r template that always prints ans Binary Search
USACO 2026
5-BinarySearch (2/9)
04-01 Replacement updates Remove the old contribution, update, add the new one: delta = new - old USACO 2026 —
03-29 Make it work, make it fast Brute force first, then only update affected rectangles; size() is unsigned and wraps around Integer Types & Overflow
USACO 2026
—
03-22 Purchasing Milk, bit operations CLion templates and Reformat Code; powers-of-two deals; shifts, AND, OR, XOR; sum constraints over test cases Bitmasks & Bit Operations
Complexity & Constraints
USACO 2026
—
03-18 USACO 2026 Contest 3 review Full solve of Contest 3; time-complexity table for a 1-second limit Complexity & Constraints
USACO 2026
—
03-08 Bitmask enumeration, fast power Enumerating all 2^n choices with state >> i & 1, spotting patterns and cycles in huge inputs Bitmasks & Bit Operations
Fast Power & Modulo
4-quick_power (3/4)
03-01 std::set (problem set 3) Unique sorted elements, iteration, begin / prev(end), find and erase; date taken from the problem set's submissions std::set 3-set (2/2)
02-08 Comparators, struct, Big-O String concatenation, the cmp rule "should x come before y?", struct, growth of complexities Sorting & Comparators
Complexity & Constraints
2-custom_sorting (2/4)
02-01 sort, iterators, custom sorting Math symbols, sort / swap / reverse on [begin, end), iterators, comparator functions Sorting & Comparators 1-vector_sort (5/11)
01-11 STL containers Pointers and references, vector / stack / queue / deque, vector as a stack, empty() STL Containers 1-vector_sort (5/11)

Topics by area

Problem sets

Dates come from submission history.

# Set Period Solved Avg. Rating
1 1-vector_sort 2026-01-31 ~ 2026-02-08 5/11 945
2 2-custom_sorting 2026-02-15 ~ 2026-02-19 2/4 850
3 3-set 2026-03-01 ~ 2026-03-01 2/2 900
4 4-quick_power 2026-03-05 ~ 2026-03-08 3/4 1225
5 5-BinarySearch 2026-04-16 ~ 2026-04-23 2/9 1144
6 6-TwoPointers 2026-05-03 ~ 2026-05-14 6/7 1271
7 7-Greedy 2026-05-10 ~ 2026-06-03 9/10 920
8 8-Graph 2026-10-10 ~ 2026-10-31 6/11 1122

8 problem sets, 58 problems, 35 solved.

Contests

Credits & licenses

This is a free, non-commercial study resource made from Liam's lessons. Explanations, worked examples and AIO write-ups are ours; lesson notes and in-class code are reproduced unchanged. Problem statements are summarised in our own words and link to the originals on Codeforces, ORAC and USACO. Where a page borrows an idea or a figure from OI Wiki (CC BY-SA 4.0) or USACO Guide (CC BY-NC-SA 4.0), its own credits box says exactly what and from whom.