A structured collection of algorithm challenges to prepare for 60-minute technical interviews.
- Arrays & Strings - Manipulation, searching, transformations
- Hash Maps & Sets - Fast lookups, frequency counting
- Two Pointers - Array traversal optimization
- Sliding Window - Subarray/substring problems
- Linked Lists - Traversal, manipulation, cycle detection
- Trees & Binary Search Trees - Traversal, searching, validation
- Graphs - BFS, DFS, connectivity
- Binary Search - Efficient searching in sorted data
- Recursion & Backtracking - Problem decomposition
- Dynamic Programming - Optimization problems (medium level)
interview-prep/
easy/ # Beginner-friendly challenges
[challenge-name]/
problem.md # Problem description & function skeleton
solution.js # Your implementation
test.js # Pre-written test cases
medium/ # Intermediate difficulty challenges
[challenge-name]/
problem.md
solution.js
test.js
- Choose a challenge from the
easy/
ormedium/
directory - Read the problem in
problem.md
- Implement your solution in
solution.js
using the provided skeleton - Run the tests to validate your solution:
node [challenge-name]/test.js
Each challenge includes pre-written test cases. Navigate to the challenge directory and run:
# Example
node easy/two-sum/test.js
Tests use Node.js built-in assert
module - no additional dependencies required.
- Start with easy challenges to build confidence
- Time yourself (aim for 15-20 minutes per easy problem, 25-35 for medium)
- Focus on clarity and correctness first, then optimize
- Practice explaining your approach out loud
- Review multiple solutions after solving
- Complete all easy challenges
- Complete all medium challenges
- Revisit and optimize solutions
- Practice whiteboard explanations
Good luck with your interview preparation! π―