Goal: Master 14 algorithmic patterns through ~42 curated problems over 14 weeks as part of #100DaysOfCode.
Each pattern contains 3 problems with clean, well-commented TypeScript solutions.
Prerequisites: Basic TypeScript and data structures knowledge
Why these 14 patterns?
These are some of the most common patterns that appear in coding interviews. Mastering them builds problem-solving intuition rather than rote memorization. By recognizing patterns, the aim is to develop transferable skills that help us recognize and solve new problems efficiently.
The list below is subject to change:
Week 1: Sliding Window
- substring-nonrepeating.ts - Longest Substring Without Repeating Characters - Medium
- longest-common-prefix.ts - Longest Common Prefix - Easy
- needle-haystack.ts - Find Needle in Haystack (String Matching) - Easy
Week 2: Two Pointers
- two-sum.ts - Two Sum (Sorted Array variant) - Easy
- common-elements.ts - Common Elements in Sorted Arrays - Easy
- reverse-array.ts - Reverse Array In-Place - Easy
Week 3: Fast & Slow Pointers
- kth-to-last-node.ts - Kth to Last Node in Linked List - Medium
- reverse-linked-list.ts - Reverse Linked List - Easy
- duplicate-number.ts - Find Duplicate Number (Floyd's Cycle Detection) - Medium
Week 4: Merge Intervals
- merge-ranges.ts - Merge Overlapping Ranges - Medium
- Insert Interval - Medium (supplement needed)
- Meeting Rooms II - Medium (supplement needed)
Week 5: Binary Search
- find-in-ordered-set.ts - Binary Search in Ordered Set - Easy
- Search in Rotated Sorted Array - Medium (supplement needed)
- Find Minimum in Rotated Sorted Array - Medium (supplement needed)
Week 6: Tree BFS / DFS
- bst-breadth-first.ts - BST Breadth-First Traversal - Medium
- bst-height.ts - BST Height (DFS) - Easy
- max-depth.ts - Maximum Depth of Binary Tree - Easy Additional tree problems to consider: bst-min-max.ts, bst-reverse.ts, bst-sum.ts, valid-bst.ts
Week 7: Graph Traversal & Recursion on Nested Structures
- nested-array-max.ts - Find Max in Nested Array (DFS/Recursion) - Medium
- nested-keyword-count.ts - Count Keywords in Nested Structure - Medium
- retrieve-depth.ts - Retrieve Depth of Nested Structure - Medium Note: These problems practice DFS/recursion on nested structures, preparing for matrix/graph problems
Week 8: Heap / Stack / Queue
- balanced-parens.ts - Balanced Parentheses (Stack) - Easy
- stack-queue.ts - Implement Stack/Queue - Easy
- linked-list-remove.ts - Remove Linked List Elements - Easy Additional: doubly-linked-list.ts
Week 9: Top K Elements & Frequency Problems
- mode.ts - Find Mode (Most Frequent Element) - Easy
- Top K Frequent Elements - Medium (supplement needed)
- Kth Largest Element - Medium (supplement needed)
Week 10: Backtracking
- generate-parentheses.ts - Generate Valid Parentheses - Medium
- subset-sum-closest.ts - Subset Sum Closest to Target - Medium
- Permutations - Medium (supplement needed)
Week 11: Dynamic Programming
- Climbing Stairs - Easy (supplement needed)
- House Robber - Medium (supplement needed)
- Coin Change - Medium (supplement needed) Note: subset-sum-closest.ts can also be solved with DP as bonus approach
Week 12: Greedy Algorithms
- apple-stocks.ts - Best Time to Buy/Sell Stock - Easy
- get-all-products.ts - Product of Array Except Self - Medium
- Jump Game - Medium (supplement needed)
Week 13: Bit Manipulation & Math
- bin-to-dec.ts - Binary to Decimal Conversion - Easy
- pow.ts - Power Function (Binary Exponentiation) - Medium
- fizzbuzz.ts - FizzBuzz - Easy
Week 14: Design & Implementation Patterns
- event-emitter.ts - Event Emitter Implementation - Medium
- fast-cache.ts - LRU Cache Implementation - Medium
- throttle.ts - Throttle Function Implementation - Medium
Follow my #100DaysOfCode journey @ www.linkedin.com/in/jamilagibson
Markdown Formatting and Syntax: https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax
This project is licensed under the MIT License - see the LICENSE file for details.
Feel free to use this repo for your own learning journey!