A curated collection of my LeetCode solutions in Python, organized by topic and difficulty. This repository documents my journey of mastering Data Structures & Algorithms (DSA) and preparing for technical interviews.
This repository contains clean and optimized Python solutions to LeetCode problems. Each solution is written with readability and efficiency in mind and, where applicable, includes:
- Problem description
- Approach and intuition
- Time complexity
- Space complexity
- Well-structured Python implementation
The primary goal of this repository is to improve problem-solving skills, strengthen algorithmic thinking, and serve as a reference for common interview patterns.
LeetCode-Solutions/
│
├── Arrays/
├── Strings/
├── Hashing/
├── Two Pointers/
├── Sliding Window/
├── Stack/
├── Binary Search/
├── Linked List/
├── Trees/
├── Graphs/
├── Heap/
├── Backtracking/
├── Dynamic Programming/
├── Greedy/
└── README.md
- Arrays
- Strings
- Hash Maps
- Two Pointers
- Sliding Window
- Stack
- Queue
- Binary Search
- Linked Lists
- Trees
- Binary Search Trees
- Graphs
- Breadth-First Search (BFS)
- Depth-First Search (DFS)
- Heap / Priority Queue
- Backtracking
- Dynamic Programming
- Greedy Algorithms
- Bit Manipulation
- Trie
- Union Find
Each problem directory contains:
solution.py– Python solutionREADME.md(optional) – Explanation of the approach, intuition, and complexity analysis
Example:
# Time Complexity: O(n)
# Space Complexity: O(1)
class Solution:
def twoSum(self, nums, target):
...| Topic | Status |
|---|---|
| Arrays & Hashing | In Progress |
| Two Pointers | In Progress |
| Sliding Window | In Progress |
| Stack | In Progress |
| Binary Search | In Progress |
| Linked List | In Progress |
| Trees | In Progress |
| Graphs | In Progress |
| Dynamic Programming | In Progress |
This repository is continuously updated as I solve new problems and refine existing solutions.
- Solve 100+ LeetCode problems
- Master fundamental data structures and algorithms
- Recognize common interview patterns
- Write clean, efficient, and maintainable Python code
- Build a comprehensive reference for technical interview preparation
These solutions are intended for educational purposes and personal learning. Whenever possible, attempt each problem independently before reviewing a solution.