Coding Interview Roadmap: A Step-by-Step Learning Path
Preparing for coding interviews is easier when you follow a clear order. This roadmap lists every guide on LeetPrep in the sequence we recommend, explains what to learn at each stage, and gives you a short checklist so you know when you are ready to move on. You do not need to read everything in one sitting. Pick the stage that matches your level and work forward.
How to use this roadmap
- Read the guide for the stage, then close it and solve two or three practice problems on your own.
- Write down the pattern and any mistakes in a notebook.
- Check the stage checklist. If you cannot do an item without help, repeat the stage.
If you have a specific interview date, pair this page with our 30-day study plan, which turns the stages into a day-by-day schedule.
Stage 1: tools and complexity
Before any algorithm, learn how to measure it and which Python tools to use. Understanding Big O lets you explain why one solution is better than another, and knowing Python’s built-in structures saves time and avoids hidden performance traps.
- Big O Notation Explained for Coding Interviews
- Python for Coding Interviews: The Complete Cheat Sheet
Checklist: you can state the complexity of a simple loop, a nested loop and a binary search, and you know the cost of x in list versus x in set.
Stage 2: arrays, strings and hash maps
These topics make up a large share of easy and medium questions. The key ideas are using a hash map to replace a search, using two indexes instead of two loops, and keeping a moving window over contiguous data.
- Two Sum Explained: From Brute Force to an O(n) Hash Map
- Two Pointers Technique in Python
- Sliding Window Pattern Explained
- Prefix Sum Technique in Python
- Build a Hash Table from Scratch in Python
- Bit Manipulation in Python: Interview Tricks Explained
Checklist: you can recognise when a hash map, two pointers or a sliding window applies, and you can write each from memory.
Stage 3: searching
Binary search looks simple but causes many off-by-one errors. Learn two reliable templates and the idea of searching on the answer.
Checklist: you can write both templates without looking and explain why the loop ends.
Stage 4: linked lists
Linked list questions test careful pointer handling. The dummy node and the fast and slow pointer patterns solve most of them.
Checklist: you can reverse a list, detect a cycle and merge two sorted lists in under ten minutes each.
Stage 5: trees and graphs
Almost every tree and graph problem comes down to depth-first or breadth-first search. Practise both until you can write them without hesitation, then apply them to grids.
- Tree and Graph Traversals in Python
- Union-Find in Python: Find, Union and Cycle Detection
- Dijkstra’s Algorithm in Python: Shortest Path with heapq
- Trie in Python: Prefix Search and Wildcard Matching
Checklist: you can write recursive and iterative traversals, choose between DFS and BFS, and handle a visited set.
Stage 6: dynamic programming
Dynamic programming becomes manageable once you follow a recipe: define the state, write the transition, set base cases and choose an order.
- Dynamic Programming for Beginners
- Knapsack and LIS in Python: Two DP Patterns Explained
- Greedy Algorithms in Python: When Taking the Best Now Works
- Merge Intervals in Python: Sorting Patterns for Interviews
Checklist: you can solve Climbing Stairs, House Robber and Coin Change and explain the state of each.
Stage 7: system design
For mid-level and senior roles, system design is often a deciding round. Learn a repeatable framework and practise explaining trade-offs.
Checklist: you can clarify requirements, make rough capacity estimates, sketch a high-level design and discuss at least two trade-offs.
Preparing for a campus or service-company test?
Online coding rounds reward clean input handling and edge cases more than advanced algorithms. Use TCS NQT and Infosys Coding Practice in Python alongside stages 1 and 2.
How long does each stage take?
Most learners need about three to five days per stage when studying one to two hours a day. If you already work with Python and data structures, you may move faster through stages 1 and 2. Spend extra time on stages 5 and 6 if you are new to recursion.
Common roadmap mistakes
- Skipping the basics. Jumping straight to dynamic programming without hash maps and recursion makes everything harder.
- Reading without practising. A guide only helps when you solve problems yourself afterwards.
- Never reviewing. Revisit earlier stages every week so the patterns stay fresh.
- Ignoring communication. Practise explaining your approach aloud, because interviewers evaluate it.
What comes next
We add new guides regularly. You can browse everything by topic on the articles page, see every page on the sitemap, or tell us what to cover next through the contact page.