A structured 10-week program to master coding interview patterns
Build on your moveZeros knowledge!
Core Concept: Use two indices to traverse data structures efficiently
Must-Do Problems:
- Two Sum II (LeetCode 167) - Easy ⭐
- 3Sum (LeetCode 15) - Medium ⭐⭐⭐
- Container With Most Water (LeetCode 11) - Medium ⭐⭐⭐
- Trapping Rain Water (LeetCode 42) - Hard ⭐⭐⭐⭐⭐
- Valid Palindrome (LeetCode 125) - Easy ⭐
Practice Problems:
- Remove Duplicates from Sorted Array (LeetCode 26)
- Squares of Sorted Array (LeetCode 977)
- 4Sum (LeetCode 18)
Key Insights:
- Always consider if array is sorted
- Look for "pair" or "triplet" problems
- Optimize from O(n²) to O(n)
Master the lookup pattern
Core Concept: O(1) lookups for frequency counting and complement finding
Must-Do Problems:
- Two Sum (LeetCode 1) - Easy ⭐⭐⭐
- Group Anagrams (LeetCode 49) - Medium ⭐⭐⭐
- Top K Frequent Elements (LeetCode 347) - Medium ⭐⭐⭐
- Longest Consecutive Sequence (LeetCode 128) - Medium ⭐⭐⭐⭐
- Contains Duplicate (LeetCode 217) - Easy ⭐
Practice Problems:
- Valid Anagram (LeetCode 242)
- First Unique Character (LeetCode 387)
- Intersection of Two Arrays (LeetCode 349)
Master the subarray/substring pattern
Core Concept: Maintain a window that slides over data to find optimal solutions
Must-Do Problems:
- Best Time to Buy/Sell Stock (LeetCode 121) - Easy ⭐⭐⭐
- Longest Substring Without Repeating (LeetCode 3) - Medium ⭐⭐⭐⭐⭐
- Minimum Window Substring (LeetCode 76) - Hard ⭐⭐⭐⭐⭐
- Sliding Window Maximum (LeetCode 239) - Hard ⭐⭐⭐⭐
- Max Consecutive Ones III (LeetCode 1004) - Medium ⭐⭐⭐
Practice Problems:
- Maximum Average Subarray (LeetCode 643)
- Permutation in String (LeetCode 567)
- Longest Repeating Character Replacement (LeetCode 424)
Master the search space reduction
Core Concept: Reduce search space by half in each iteration
Must-Do Problems:
- Binary Search (LeetCode 704) - Easy ⭐
- Search in Rotated Sorted Array (LeetCode 33) - Medium ⭐⭐⭐⭐
- Find First/Last Position (LeetCode 34) - Medium ⭐⭐⭐
- Search 2D Matrix (LeetCode 74) - Medium ⭐⭐
- Koko Eating Bananas (LeetCode 875) - Medium ⭐⭐⭐
Practice Problems:
- Sqrt(x) (LeetCode 69)
- Peak Index in Mountain Array (LeetCode 852)
- Time Based Key-Value Store (LeetCode 981)
Master the cycle detection pattern
Core Concept: Two pointers moving at different speeds to detect patterns
Must-Do Problems:
- Linked List Cycle (LeetCode 141) - Easy ⭐⭐⭐
- Linked List Cycle II (LeetCode 142) - Medium ⭐⭐⭐⭐
- Middle of Linked List (LeetCode 876) - Easy ⭐⭐
- Happy Number (LeetCode 202) - Easy ⭐⭐
- Find Duplicate Number (LeetCode 287) - Medium ⭐⭐⭐⭐
Practice Problems:
- Remove Nth Node From End (LeetCode 19)
- Palindrome Linked List (LeetCode 234)
- Intersection of Two Linked Lists (LeetCode 160)
Master the LIFO/FIFO patterns
Core Concept: Use stacks for nesting/matching, queues for level processing
Must-Do Problems:
- Valid Parentheses (LeetCode 20) - Easy ⭐⭐⭐
- Min Stack (LeetCode 155) - Medium ⭐⭐⭐
- Daily Temperatures (LeetCode 739) - Medium ⭐⭐⭐⭐
- Largest Rectangle in Histogram (LeetCode 84) - Hard ⭐⭐⭐⭐⭐
- Evaluate Reverse Polish Notation (LeetCode 150) - Medium ⭐⭐
Practice Problems:
- Implement Queue using Stacks (LeetCode 232)
- Next Greater Element (LeetCode 496)
- Basic Calculator (LeetCode 224)
Master tree and graph fundamentals
Core Concept: Systematic exploration of tree/graph structures
Must-Do Problems:
- Maximum Depth of Binary Tree (LeetCode 104) - Easy ⭐⭐
- Same Tree (LeetCode 100) - Easy ⭐⭐
- Invert Binary Tree (LeetCode 226) - Easy ⭐⭐⭐
- Binary Tree Level Order (LeetCode 102) - Medium ⭐⭐⭐⭐
- Validate BST (LeetCode 98) - Medium ⭐⭐⭐⭐
Practice Problems:
- Symmetric Tree (LeetCode 101)
- Path Sum (LeetCode 112)
- Binary Tree Right Side View (LeetCode 199)
Master graph traversal and connectivity
Core Concept: Apply DFS/BFS to solve graph problems
Must-Do Problems:
- Number of Islands (LeetCode 200) - Medium ⭐⭐⭐⭐⭐
- Clone Graph (LeetCode 133) - Medium ⭐⭐⭐
- Course Schedule (LeetCode 207) - Medium ⭐⭐⭐⭐
- Pacific Atlantic Water Flow (LeetCode 417) - Medium ⭐⭐⭐⭐
- Word Ladder (LeetCode 127) - Hard ⭐⭐⭐⭐
Practice Problems:
- Surrounded Regions (LeetCode 130)
- Rotting Oranges (LeetCode 994)
- Network Delay Time (LeetCode 743)
Master the optimization pattern
Core Concept: Break problems into overlapping subproblems
Must-Do Problems:
- Climbing Stairs (LeetCode 70) - Easy ⭐⭐
- House Robber (LeetCode 198) - Medium ⭐⭐⭐⭐
- Coin Change (LeetCode 322) - Medium ⭐⭐⭐⭐⭐
- Longest Increasing Subsequence (LeetCode 300) - Medium ⭐⭐⭐⭐
- Word Break (LeetCode 139) - Medium ⭐⭐⭐⭐
Practice Problems:
- Maximum Subarray (LeetCode 53)
- Decode Ways (LeetCode 91)
- Jump Game (LeetCode 55)
Master specialized patterns
Core Concept: Combine multiple patterns for complex problems
Must-Do Problems:
- Merge Intervals (LeetCode 56) - Medium ⭐⭐⭐⭐
- Insert Interval (LeetCode 57) - Medium ⭐⭐⭐
- Meeting Rooms II (LeetCode 253) - Medium ⭐⭐⭐⭐
- Kth Largest in Array (LeetCode 215) - Medium ⭐⭐⭐
- Top K Frequent Words (LeetCode 692) - Medium ⭐⭐⭐
Practice Problems:
- Non-overlapping Intervals (LeetCode 435)
- Find Median from Data Stream (LeetCode 295)
- Alien Dictionary (LeetCode 269)
- 10 min: Read pattern theory
- 20 min: Watch tutorial/explanation
- 45 min: Solve 1-2 easy problems
- 15 min: Review solutions, note patterns
- 15 min: Quick pattern review
- 60 min: Solve 2-3 medium problems
- 15 min: Analyze time/space complexity
- 90 min: Attempt 1-2 hard problems
- 30 min: Study editorial solutions
- No time pressure - focus on learning
- 30 min: Review week's patterns
- 45 min: Mock interview (random problems)
- 15 min: Identify weak areas
- Week 1-2: 80% easy, 20% medium
- Week 3-6: 60% medium, 40% easy
- Week 7-10: 70% medium, 30% hard
- Pattern Recognition: Identify correct pattern in 2-3 minutes
- Implementation: Code solution in 15-25 minutes
- Bug-Free: First submission acceptance rate > 70%
- Optimization: Achieve optimal complexity
| Problem | Pattern | Difficulty | Time Taken | Attempts | Date | Notes |
|---------|---------|------------|------------|----------|------|--------|
| Two Sum | HashMap | Easy | 8 min | 1 | 2024-01-01 | Easy win |
- What pattern does this remind me of?
- What's the brute force approach?
- Can I optimize the time/space complexity?
- Look at the problem tags (but not solution)
- Read the first paragraph of editorial
- Watch first 5 minutes of explanation video
- Study complete solution
- Understand every line
- Code it from memory next day
- Mark for review in 1 week
- Week 2: Complete Basic Patterns Badge 🥉
- Week 5: Intermediate Problem Solver 🥈
- Week 8: Advanced Algorithm Master 🥇
- Week 10: Interview Ready Certification 🏆
- LeetCode: Pattern-based problem lists
- NeetCode: Video explanations + roadmap
- AlgoExpert: Comprehensive video course
- Grokking the Coding Interview: Pattern-focused book
- Elements of Programming Interviews: Deep problem analysis
- Cracking the Coding Interview: Interview context
- LeetCode: Best for pattern recognition
- HackerRank: Good for contest practice
- CodeSignal: Company-specific practice
- Pramp: Mock interviews with peers
- Focus on: Binary Search, DFS/BFS, DP
- Practice: Complex algorithm design
- Mock: 2-3 rounds, 45 min each
- Focus on: Graph algorithms, System design integration
- Practice: Social network problems
- Mock: Behavioral + 2 technical rounds
- Focus on: Two pointers, Heap, Real-world scenarios
- Practice: Leadership principles integration
- Mock: Bar raiser round simulation
- Consistency > Intensity: 1-2 hours daily beats 8-hour weekends
- Understand, Don't Memorize: Focus on pattern recognition
- Code by Hand: Practice without IDE occasionally
- Explain Out Loud: Teach problems to solidify understanding
- Track Progress: Maintain detailed logs of your journey
- Stay Positive: Coding interviews are learnable skills!
Start with Week 1 (Two Pointers) since you already have a foundation with your moveZeros problem. You're already ahead of the game! 🎯
Remember: This roadmap is flexible. Adjust based on your pace and comfort level. The key is consistent progress, not perfect adherence to the timeline.