A coding interview study plan, pattern by pattern
A good coding interview study plan works through problem patterns in a fixed order, a few problems per pattern, and revisits each problem a few days and again a week or two later. Pick the length from your starting point: about two weeks to refresh if you interview often, about six weeks if you know the data structures but are rusty, and ten or more if you are learning them for the first time. Every week should include timed, spoken practice, not just silent solving.
By Evin JohnPublished 7 min read
Start with a baseline, not a schedule
Before you plan anything, find out where you are. Pick two problems of moderate difficulty from different areas, for example one on arrays and one on trees, set a timer for 40 minutes each, and solve them while talking out loud. Note three things: whether you finished, how long it took to see the approach, and which part felt shaky (the idea, the code, or the testing). That baseline decides the length of the plan and where to spend extra days.
| Starting point | Rough plan length | Shape of the plan |
|---|---|---|
| Finished both baseline problems; you interviewed in the last year | About 2 weeks | One pattern a day, timed mocks every few days, heavy on review |
| Know the data structures, but slow or stuck on one baseline problem | About 6 weeks | Two patterns a week, a mock each weekend, spaced redo of every problem |
| Could not start either problem, or new to data structures | 10 weeks or more | Learn each data structure first, then its patterns, with easier problems before medium ones |
This page covers coding rounds only. If you also face behavioral, design or company-research rounds, the four-week interview prep plan fits coding into a wider schedule.
The pattern order
Learning by pattern, not by random problem, is what makes new problems feel familiar. Each pattern builds on the one before: windows need arrays and hashing, graphs need the traversal you learned on trees, and dynamic programming is easier once recursion is comfortable. The walkthroughs linked below each restate a problem and solve it from brute force to optimal.
| Week | Patterns | Walkthroughs to start with |
|---|---|---|
| 1 | Arrays and hash maps; counting and frequency | Two Sum, Top K Frequent Elements |
| 2 | Two pointers and sliding window; stacks | Longest Substring Without Repeating Characters, Valid Parentheses |
| 3 | Sorting and intervals; binary search | Merge Intervals, plus two binary search problems of your choice |
| 4 | Trees (BFS and DFS); graphs on grids | Binary Tree Level Order Traversal, Number of Islands |
| 5 | Heaps and design-style problems; weighted graphs | LRU Cache, Min Cost to Connect All Points |
| 6 | Dynamic programming in one and two dimensions | House Robber, Coin Change, Palindromic Substrings |
For the two-week version, take one row per day or two and skip the extra problems. For a longer plan, spend a few days learning each data structure (how a hash map, a heap or a queue behaves, and what each operation costs) before the matching row, and add backtracking and linked lists as their own weeks. The data structure interview questions and algorithm interview questions pages cover that theory.
A weekly rhythm that fits around a job
- Day 1: learn the patternRead one walkthrough end to end. Write the template from memory afterwards, and note the clue in a problem statement that points to this pattern.
- Days 2 and 3: two or three problems, timedGive yourself about 30 to 40 minutes each, out loud. If you are stuck after about 20 minutes with no idea at all, read only the approach, close it, and write the code yourself.
- Day 4: second patternSame as day 1 for the week's second pattern.
- Days 5 and 6: problems for the second pattern, plus one redoRe-solve one problem from earlier in the week without looking at your old code.
- Day 7: a mock round and the review listOne 45-minute mock with a friend or a timer, on a problem you have not seen. Then redo anything on your review list that came due.
Speak during every timed problem, even alone. Interviews grade explanation as well as code, and narrating is a separate skill from solving. How to think out loud in a coding interview gives a script for each phase.
Spaced review: the part most plans skip
Solving a problem once mostly proves you could follow the idea that day. Solving it again from a blank file a few days later proves you own it. Keep a list. Each time you finish a problem, give it a redo date roughly three days out. If the redo is clean, push the next one out to about ten days. If you stumble, reset it to three days. A problem leaves the list after two clean redos in a row. The exact gaps matter less than the habit of coming back.
| Column | What to write |
|---|---|
| Problem | Name and link |
| Pattern | The pattern you think it belongs to, in your own words |
| Clue | The phrase in the statement that pointed to the pattern |
| First try | Date, minutes taken, solved alone / with a hint / read the approach |
| Mistake | The one thing that went wrong, such as an off-by-one in the window or a missed empty case |
| Next redo | Date, based on how the last attempt went |
| Redo results | Clean or stumbled, with the date |
The Mistake column is the most useful one over time. After a few weeks, the same two or three mistakes usually account for most of your failed attempts, and those are what to drill in the final week.
What a week can look like
Fictional example
- Monday
- 45 minutes: read the level order traversal walkthrough, then wrote BFS and DFS templates from memory. Clue noted: "level by level" or "nearest" means BFS.
- Tuesday
- 60 minutes: two tree problems, 35 and 40 minutes, out loud. Second one needed a hint about passing depth down the recursion. Logged it.
- Wednesday
- 50 minutes: grid flood fill walkthrough, then a counting-regions problem in 30 minutes. Redo of a sliding window problem from week 2: clean.
- Thursday
- Skipped, late meeting. Moved Thursday's problem to Saturday instead of doubling up Friday.
- Friday
- 40 minutes: a shortest-path-on-a-grid problem. Missed marking cells visited when queued, so cells were counted twice. Logged the mistake.
- Saturday
- 45-minute mock with a colleague on an unseen graph problem: solved, but spent 12 minutes before saying the approach. Then the missed Thursday problem and two redos.
How to tell you are ready
- You can name a plausible pattern for a new medium problem within the first five minutes, and explain why it fits.
- You finish most medium problems with working code and a test trace inside about 40 minutes, while talking.
- Your review list is mostly clean redos, and the Mistake column has stopped growing in new directions.
- You can state time and space for your solution without working it out from scratch.
- In mocks, your explanation is short. The concise answers guide applies to technical explanations as well.
Choosing a language
Use the language you write fastest and most correctly, unless the role or the interview instructions name one. Python is a common choice because the code is short and the standard library covers heaps, counters and deques. JavaScript and C++ are fine too; know how your language sorts, how it handles integer size, and which structure plays the role of a heap. Switching languages in the last two weeks usually costs more than it gains.
Mistakes to avoid
- Counting problems solved instead of patterns owned. A high count with no redos often hides gaps.
- Reading the full solution the moment you are stuck. Read only the idea, then write the code yourself.
- Practicing in silence, then being surprised by how hard it is to talk and code at once.
- Never timing yourself, so the first time pressure appears is in the real round.
- Skipping the patterns you dislike. Interviewers pick the problem, not you.
- Cramming the night before. A light review and sleep help more than one more hard problem.
Where Natively fits
Two parts of this plan benefit from a tool: checking an approach after you have tried it, and reviewing how you explained it. On Mac or Windows, Natively can read a practice problem from a screenshot and offer an approach with code, which you can compare with your own attempt once you have made it. It also transcribes your timed sessions and mocks and saves them, so the Mistake column can come from what you actually said, not from memory. The AI interview assistant page explains the setup.
Questions people ask
How long should I study for a coding interview?
It depends on your starting point. About two weeks is often enough to refresh if you interview regularly, about six weeks if you know the data structures but are rusty, and ten or more if you are learning them for the first time.
What order should I study coding interview topics in?
Start with arrays and hash maps, then two pointers and sliding windows, stacks, sorting and intervals, binary search, trees, graphs, heaps, and finish with dynamic programming. Each step builds on the ones before.
How many problems should I solve to prepare for coding interviews?
Aim for two to four problems per pattern, timed and explained out loud, and redo each one from scratch a few days and again a week or two later. Patterns you can apply matter more than a total count.
How do I know I am ready for a coding interview?
When you can name a fitting pattern for a new medium problem within a few minutes, finish most medium problems with tests in about 40 minutes while talking, and your redos are mostly clean.
Where to go next
Practice with the same assistant you would use on a call: it listens, transcribes and suggests answers from your own resume and the job description.
Facts on this page were last checked on . Product details come from the Natively app itself; if something here is out of date, tell us at hello@heynatively.com.
