Appendix B — Appendix B: LeetCode Index

Appendix B: LeetCode Index

Every LeetCode problem referenced in this book, organized by chapter. Each links to the problem; many also have my own submission archive at ~/leetcode-submissions/ for comparison.

B.1 Problems by chapter

B.1.1 Chapter 2 — STL vector

B.1.2 Chapter 3 — STL set/map/stack/queue

B.1.3 Chapter 4 — Pointers

B.1.4 Chapter 5 — Classes

B.1.5 Chapter 8 — Templates

B.1.6 Chapter 9 — Recursion

B.1.7 Chapter 14 — Sorting

B.1.8 Chapter 16 — Linked Lists

B.1.9 Chapter 17 — Binary Trees Intro

B.1.10 Chapter 18 — Advanced Recursion

B.1.11 Chapter 22 — Trees revisited

B.1.12 Chapter 23 — BST delete

B.1.13 Chapter 25 — Heaps

B.1.14 Chapter 26 — Graphs BFS/DFS

B.1.15 Chapter 27 — Shortest paths and MST

B.1.16 Chapter 28 — Hash tables

B.1.17 Chapter 29 — Balanced trees

B.1.18 Chapter 31 — Divide and conquer

B.1.19 Chapter 32 — Greedy

B.1.20 Chapter 33 — DP I

B.1.21 Chapter 34 — DP II

B.1.22 Chapter 37 — Regex

B.2 By difficulty (rough)

B.2.1 Easy

  • #1 Two Sum
  • #9 Palindrome Number
  • #20 Valid Parentheses
  • #21 Merge Two Sorted Lists
  • #70 Climbing Stairs
  • #88 Merge Sorted Array
  • #104 Maximum Depth of Binary Tree
  • #141 Linked List Cycle
  • #198 House Robber
  • #206 Reverse Linked List
  • #226 Invert Binary Tree
  • #344 Reverse String
  • #509 Fibonacci Number
  • #704 Binary Search
  • #876 Middle of the Linked List

B.2.2 Medium

  • #3 Longest Substring Without Repeating Characters
  • #45 Jump Game II
  • #49 Group Anagrams
  • #62 Unique Paths
  • #75 Sort Colors
  • #78 Subsets
  • #98 Validate BST
  • #102 Level Order Traversal
  • #122 Best Time to Buy and Sell Stock II
  • #133 Clone Graph
  • #134 Gas Station
  • #146 LRU Cache
  • #200 Number of Islands
  • #207 Course Schedule
  • #210 Course Schedule II
  • #215 Kth Largest
  • #300 Longest Increasing Subsequence
  • #322 Coin Change
  • #347 Top K Frequent
  • #416 Partition Equal Subset Sum
  • #450 Delete BST Node
  • #543 Diameter of Binary Tree
  • #621 Task Scheduler
  • #743 Network Delay
  • #912 Sort an Array
  • #1143 Longest Common Subsequence
  • #1584 Min Cost to Connect All Points

B.2.3 Hard

  • #23 Merge k Sorted Lists
  • #72 Edit Distance
  • #295 Find Median from Data Stream
  • #315 Count of Smaller Numbers After Self
  • #787 Cheapest Flights Within K Stops

B.3 Where to find my submissions

Most of the problems above I have submitted multiple times over the years. Solutions live in ~/leetcode-submissions/ organized by problem slug. Filenames are timestamped, so the latest file is usually the cleanest. Older ones often show the evolution — first attempt, optimized version, alternative approach.