Intermediate · Free course
DSA and Coding Problems
Every classic data structure and algorithm, solved from brute force to optimal.
90 lessons9 videos so far2 h 2 min of videoNotes for every lesson
What you’ll learn
- Arrays, strings and hashing
- Linked lists, stacks and queues
- Trees, graphs and heaps
- Dynamic programming and greedy
0 of 90 complete
Curriculum
- 1Big-O and reading constraints: which complexity fits the time limit11 min
- 2Two Sum (hashing)soon
- 3Best Time to Buy and Sell Stock (running minimum)soon
- 4Kadane's algorithm: maximum subarraysoon
- 5Prefix sums: subarray sum equals K12 min
- 6Two pointers: 3Sumsoon
- 7Container With Most Watersoon
- 8Trapping Rain Water (hard)15 min
- 9Sliding window: longest substring without repeating characters16 min
- 10Minimum Window Substring (hard)soon
- 11Sliding Window Maximum: the monotonic deque (hard)soon
- 12Binary search: one template, first and last occurrence13 min
- 13Search in a rotated sorted array12 min
- 14Binary search on the answer: Koko eating bananas, aggressive cowssoon
- 15Median of Two Sorted Arrays (hard)12 min
- 16Sorting 1: bubble, selection, insertion sortsoon
- 17Merge sort and counting inversions16 min
- 18Quick sort and quickselect: kth largest element15 min
- 19Counting sort, radix sort and the Dutch national flagsoon
- 20Merge intervalssoon
- 21Linked lists: reverse a list, iterative and recursivesoon
- 22Floyd's cycle detection and the cycle startsoon
- 23Merge k sorted lists with a heap (hard)soon
- 24Reverse nodes in k-group (hard)soon
- 25LRU cache: hash map + doubly linked listsoon
- 26Stacks: valid parenthesessoon
- 27Monotonic stack: next greater element, daily temperaturessoon
- 28Largest rectangle in a histogram (hard)soon
- 29Min stack and evaluating reverse Polish notationsoon
- 30Queues: a queue from two stacks, the circular queuesoon
- 31Backtracking: subsets and permutationssoon
- 32Combination sumsoon
- 33N-Queens (hard)soon
- 34Sudoku solver (hard)soon
- 35Word search in a gridsoon
- 36Trees: preorder, inorder, postorder and level ordersoon
- 37Maximum depth and diameter of a binary treesoon
- 38Lowest common ancestorsoon
- 39Validate a BST and the kth smallest elementsoon
- 40Binary tree maximum path sum (hard)soon
- 41Serialize and deserialize a binary tree (hard)soon
- 42Build a tree from preorder and inordersoon
- 43Heaps: top K frequent elementssoon
- 44Median from a data stream with two heaps (hard)soon
- 45Tries: implement a trie, then Word Search II (hard)soon
- 46Hashing deep dive: longest consecutive sequence, group anagramssoon
- 47Graphs: representation, BFS and DFSsoon
- 48Number of islandssoon
- 49Rotting oranges: multi-source BFSsoon
- 50Cycle detection in undirected and directed graphssoon
- 51Topological sort: course schedule (Kahn's algorithm)soon
- 52Dijkstra's algorithm: network delay timesoon
- 53Bellman-Ford and cheapest flights within K stopssoon
- 54Floyd-Warshall: all-pairs shortest pathssoon
- 55Union-Find (DSU): provinces and redundant connectionsoon
- 56Minimum spanning tree: Kruskal and Primsoon
- 57Word ladder (hard)soon
- 58Strongly connected components and bridges (hard)soon
- 59Greedy: activity selection and jump gamesoon
- 60Gas station and task schedulersoon
- 61Huffman coding and minimum cost to connect ropessoon
- 62DP 1: Fibonacci, memoization vs tabulation, climbing stairssoon
- 63House robbersoon
- 64Coin change: fewest coins and number of wayssoon
- 650/1 knapsacksoon
- 66Longest increasing subsequence in O(n log n)soon
- 67Longest common subsequencesoon
- 68Edit distance (hard)soon
- 69Grid DP: unique paths and minimum path sumsoon
- 70Partition equal subset sumsoon
- 71Word breaksoon
- 72Palindromes: longest palindromic substring and palindrome partitioningsoon
- 73Regular expression matching (hard)soon
- 74Burst balloons: interval DP (hard)soon
- 75Matrix chain multiplicationsoon
- 76DP on trees: house robber IIIsoon
- 77Bitmask DP: the travelling salesman problem (hard)soon
- 78Bit manipulation: single number, counting bits, power of twosoon
- 79Math for coding: GCD, sieve of Eratosthenes, fast power, modular arithmeticsoon
- 80String matching: KMPsoon
- 81Rabin-Karp and the Z-algorithmsoon
- 82Segment tree: range sum with point updatessoon
- 83Fenwick tree: count of smaller numbers after self (hard)soon
- 84Sparse table and range minimum querysoon
- 85Matrix problems: rotate image, spiral order, set matrix zeroessoon
- 86Design: insert-delete-getRandom O(1) and the LFU cache (hard)soon
- 87Hard mix 1: first missing positive, longest valid parenthesessoon
- 88Hard mix 2: alien dictionary, minimum cost to cut a sticksoon
- 89How to crack any problem: recognising the patternsoon
- 90Mock interview: two hard problems end to endsoon