LeetCode
Medium and hard problems, one at a time. Guess the idea first, open each step, and see the code last.
How to use this
- Read the problem. Then stop and guess: which pattern is it, and roughly how would you solve it? A wrong guess is fine. Guessing is what makes it stick.
- Open Concept and Why it fits and check your guess against them.
- Open Steps. Read them, close the fold, and try to say the steps in your own words.
- Do Try by hand on paper, then open Answers to check.
- Read the Key idea. It's the one line to remember.
- Open the Code last and match each line to a step.
To review, switch to By pattern, open an old problem, and recall its key idea before opening anything. Now and then, write the code yourself on LeetCode, using the link at the top of the problem.