maruf-pfc/MAANG-Interview-Preparation
Repovive MAANG Interview Preparation Guide
MAANG Interview Prep in C++ & C#
A highly detailed, Open-Source Interactive Notebook Curriculum for cracking Meta, Amazon, Apple, Netflix, and Google.
Welcome to the MAANG Interview Prep repository, a comprehensive, multi-language (C++ & C#) curriculum rewritten from the excellent Repovive roadmap by Shayan Chashm Jahan.
This repository transforms the roadmap into a series of highly detailed "notebooks." It is designed specifically for high-performance software engineering candidates targeting top-tier tech companies. The inclusion of C# helps reinforce Object-Oriented Programming (OOP) principles and enterprise design patterns.
π What Makes This Repository Special?
Instead of just linking out to LeetCode or dumping bare code files, every section in this repository is a standalone notebook. For all 41 problems across the 11 topics, you will find:
- The Core Concept: Why the technique matters, when to use it, and how it works mechanically.
- Problem Statement: The exact scenario you'll face.
- The Hint: A nudge in the right direction if you get stuck without reading the answer.
- Solution Explanation: Step-by-step logic detailing the algorithm.
- Pseudocode: Language-agnostic logic to help you internalize the pattern.
- Detailed Code Implementation: Production-ready C++ (C++17) code and idiomatic C# utilizing OOP paradigms.
- Complexity Analysis: Deep dive into Time and Space constraints.
- Edge Cases & Common Mistakes: What will actually trip you up in a live interview.
- Interview Context: Why MAANG companies ask this specific question.
πΊοΈ The Roadmap
The curriculum is divided into 11 strictly ordered sections. Do not skip around β the patterns build sequentially.
π§± Part 1: Fundamentals & Data Structures
- 01 Β· Understanding MAANG Interviews
- Format, expectations, and the "Pattern Approach."
- 02 Β· Arrays & Hashing
- Hash maps, frequency counting, and O(1) lookups.
- 03 Β· Two Pointers & Sliding Window
- Moving pointers to avoid nested loops, dynamic window expansion/contraction.
- 04 Β· Linked Lists
- Pointer manipulation, cycle detection (Floyd's algorithm).
- 05 Β· Stacks
- LIFO processing, matching brackets, and the powerful Monotonic Stack.
- 06 Β· Trees & BST
- DFS recursion, BFS tree traversal, Binary Search Tree properties.
π§ Part 2: Advanced Algorithmic Patterns
- 07 Β· Graphs
- Connected components, Deep Copying, cycle detection in DAGs.
- 08 Β· Binary Search
- Halving search spaces, rotated array navigation, finding minimums.
- 09 Β· Heaps & Priority Queues
- Top-K elements, streaming medians, K-way merges.
π Part 3: Mastery
- 10 Β· Dynamic Programming
- 1D sequences, unbounded knapsack, 2D Grid paths, String DP.
- 11 Β· Backtracking
- Combinatorial search trees, subsets, permutations, constrained exploration.
ποΈ Part 4: System Design & Architecture
- 12 Β· System Design
- Multi-tiered architectures, databases, load balancing, microservices, and Object-Oriented Design (OOD).
π» How to Use This Guide
- Follow the Order: Start at
01_Understanding_MAANG_Interviewsand move sequentially. - Read the Intros: Every section
README.mdbegins with a crucial Why/When/How guide mapping out the core pattern. Don't skip it. - Try Before You Peek: Read the problem statement and the hint. Try to write the C++ code yourself before looking at the provided Solution Explanation and Implementation.
- Compile & Run: Every single implementation provided in the notebooks is also available as a standalone
.cppfile in its respective directory. You can test code locally with ease. - Study the Edge Cases: The "Edge Cases" and "Common Mistakes" sections are what separate a hired candidate from a rejected one. Internalize them.
βοΈ Running Locally & Testing
All solutions are self-contained files. C++ files include a main() validation entry point, while C# files are verified for compilation against .NET syntactical correctness.
C++ Example:
cd 02_Arrays_and_Hashing
g++ -std=c++17 two_sum.cpp -o two_sum
./two_sumFull Repository Verification
We maintain a zero-broken-code policy. You can run the top-level test scripts to globally verify that every single C++ solution in the repository compiles under c++17 (and passes internal assertions) and every C# file is cleanly verified:
# Ensure scripts are executable
chmod +x test_all.sh test_all_cs.sh
# Run the full test suite via NPM
npm run test
# OR run manually
./test_all.sh
./test_all_cs.shNote: This repository uses Husky pre-commit hooks to ensure no broken code can be pushed to the repository.
π€ Contributing
We welcome contributions from the open-source community! If you find a bug, want to add a new problem, or wish to expand on an explanation, please help us make this resource even better.
- Fork the repository.
- Read our CONTRIBUTING.md guidelines. All new contributions must match the exhaustive standard set in the existing notebooks (Hint, Pseudocode, C++, Edge Cases, Interview Context).
- Install dependencies:
npm install(sets up pre-commit hooks). - Create a feature branch:
git checkout -b feature/new-problem - Commit your changes:
git commit -m "feat: add missing problem" - Push to the branch and open a Pull Request.
π License & Accreditation
This project is open-source and available under the terms of the MIT License.
The problem set and syllabus structure are based on the Repovive roadmap by Shayan Chashm Jahan. Implemented entirely in modern C++ and idiomatic C# for high-performance engineering interviews.