A curated collection of Python solutions to LeetCode problems, organized by difficulty and topic for easy navigation and learning. Each problem includes a brief description, solution file, and tutorials for deeper understanding.
🧠 Workflow • 📘 Resources • 🎯 Study Plan • 📊 Progress • 🧑💻 Contribute • 📜 Code of Conduct
- ✅ Organized by Problem ID & Difficulty (Easy / Medium / Hard)
- 📂 Solutions in separate Python files with docstrings
- 🧪 Optional pytest tests in
tests/
- ⚙️ Scripts in
tools/
for automation (generate README, new problem template) - 🔗 Tutorials and explanations for selected problems
- 📊 Progress tracker for problems solved
Difficulty | Solved | Total | Progress |
---|---|---|---|
Easy | 5 | 50 | 🟩🟩🟩⬜⬜ |
Medium | 5 | 50 | 🟩🟩⬜⬜⬜ |
Hard | 2 | 25 | 🟩⬜⬜⬜⬜ |
- LeetCode — official platform
- NeetCode.io — curated solutions
- Striver’s SDE Sheet
- Abdul Bari YouTube — DS & Algo tutorials
- CS50 Algorithms — fundamental algorithms
- GeeksforGeeks — problem explanations
- Books: Cracking the Coding Interview, Elements of Programming Interviews in Python
Week | Focus | Problems |
---|---|---|
1 | Arrays & Strings | 10 Easy, 5 Medium |
2 | Linked List, Stack, Queue | 10 Easy, 5 Medium |
3 | Trees & Recursion | 10 Medium |
4 | DP & Graphs | 5 Medium, 3 Hard |
Use tools/generate_readme_table.py
to auto-populate this table.
LeetCode-Python-Solutions/
├── README.md
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── LICENSE
├── requirements.txt
├── solutions/
│ ├── easy/
│ ├── medium/
│ ├── hard/
│ └── topics/
├── tests/
├── docs/
│ ├── workflow.md
│ ├── resources.md
│ ├── study_plan.md
│ ├── progress.md
│ └── tutorials/
├── tools/
│ ├── generate_readme_table.py
│ └── new_problem_template.py
├── .github/workflows/python-test.yml
└── assets/diagrams/
# Clone the repo
git clone https://github.com/im-vishu/LeetCode-Python-Solutions.git
cd LeetCode-Python-Solutions
# Install dependencies
pip install -r requirements.txt
# Run a specific solution
python solutions/easy/0001_two_sum.py
# Run all tests
pytest -v
Please read CONTRIBUTING.md and follow the Code of Conduct.
- Inspired by NeetCode, Striver’s SDE Sheet, and GeeksforGeeks
- Community contributions from GitHub users