Ctrl K
An Offerland course

Algorithms for Interviews

All the core techniques of algorithm interviews, from arrays to dynamic programming. Short lessons with diagrams, problems with automatic code checking, and explaining your solution out loud to an AI interviewer, just like in a real interview.

1

Getting Started

How the course works and how to evaluate solutions: Big O made simple.

0/4
How to Take This CourseComplexity: Big O Made SimpleBalance After Each DayExplain It in Your Own Words: Big O
2

Arrays and Two Pointers

When two pointers turn O(n²) into O(n).

0/6
Two PointersMirror Phrase CheckSquares in OrderPair in a Sorted ListZero-Sum TriplesExplain It in Your Own Words: Two Pointers
3

Sliding Window and Prefix Sums

Subarrays and substrings without redundant recomputation.

0/7
Sliding WindowBest Window AverageShortest Stretch to the GoalLongest Repeat-Free StretchPrefix SumsStretches With an Exact TotalExplain It in Your Own Words: Sliding Window
4

Hash Tables

O(1) lookup: the most common optimization in interviews.

0/7
Hash Tables and SetsDoes Any Value RepeatPair With a Target SumNote From Clipped LettersAnagram BucketsLongest Unbroken RunExplain It in Your Own Words: Hash Tables
5

Linked Lists

Pointers, the dummy head, and fast and slow pointers.

0/6
Linked ListsFlip the ChainMidpoint of a ListZip Two Sorted ChainsAdding Digit ListsExplain It in Your Own Words: Reversing a List
6

Stack and Queue

Brackets, "next greater," and the monotonic stack.

0/5
Stack, Queue, and Monotonic StackBracket BalanceNext Larger on the RightWaiting for a Higher PriceExplain It in Your Own Words: Monotonic Stack
7

Trees

Depth-first and breadth-first traversals, recursion without fear.

0/10
Binary Trees and RecursionTraversals: Depth-First and Breadth-FirstTree HeightMirror the TreeIdentical TreesLongest Path in a TreeTree Rows by DepthBinary Search Tree (BST)Is It a Search Tree?Explain It in Your Own Words: DFS and BFS
8

Graphs

Grids, islands and dependency order.

0/8
Graphs: Representation and TraversalLand Regions on a MapLargest Forest PatchInfection Spread TimeClusters of Linked ServersTopological SortModule Build OrderExplain It in Your Own Words: Topological Sort
9

Heap

Top-K and "the biggest one right now."

0/5
Heaps and Priority QueuesBoulder CrusherK-th Highest ScoreMost Common ValuesExplain It in Your Own Words: Heaps and Top-K
10

Binary Search

Not just in arrays: searching on the answer.

0/6
Binary SearchFind in a Sorted ListSlot on a Sorted ShelfMinimum of a Shifted ListSlowest Reading PaceExplain It in Your Own Words: Binary Search on the Answer
11

Backtracking

Subsets, permutations, and combinations.

0/6
BacktrackingEvery Topping ComboAll OrderingsWeight Sets for an Exact LoadKeypad WordsExplain It in Your Own Words: Backtracking
12

Dynamic Programming

How to turn brute force into a table.

0/9
DP: From Recursion to a TablePaving a Garden PathCheapest Climb to the TopNo Back-to-Back ShiftsFewest Bills2D Dynamic ProgrammingCounting Grid RoutesLongest Shared ThreadExplain It in Your Own Words: Dynamic Programming