Skip to content
AlbinMathPublic

About

LeetCode solutions, DSA algorithms, data structures, coding interview problems, and programming solutions in Python, C++, and JavaScript with explanations, complexity analysis, and optimized approaches. Continuously updated.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Repository files navigation

LeetCode Solutions & DSA Practice

A continuously updated collection of LeetCode solutions, algorithm explanations, data structures, and coding interview patterns.

This repository contains solved LeetCode problems with explanations, complexity analysis, and source code. Problems are organized by LeetCode number and grouped by algorithmic pattern, data structure, difficulty, and programming language.

What You'll Find

  • Comprehensive Explanations: Step-by-step algorithm walkthroughs, key insights, and common pitfalls.
  • Multi-Language Solutions: Python, C++, JavaScript, TypeScript, Java, SQL, and more.
  • Complexity Analysis: Explicit Time and Space complexity ($O(N)$, $O(\log N)$, $O(1)$) for every solution.
  • Pattern & Topic Indexing: Grouped by Binary Search, Sliding Window, Two Pointers, Hash Maps, Stacks, Trees, Graphs, Dynamic Programming, and SQL.
  • Machine-Readable Metadata: Structured JSON catalog available in metadata/problems.json.

Statistics

Category Count
Total Solved 3328+
Easy 845+
Medium 1687+
Hard 796+

Repository Structure: To prevent GitHub directory truncation (which limits folder listings to 1,000 files), all 2,360+ problems are cleanly partitioned into 500-problem range buckets under leetcode/ (0001-0500/, 0501-1000/, etc.). You can browse problems directly through their range buckets or search the full directory in All_Problems.md.


Recently Solved

# Problem Difficulty Pattern Language Solution
4128 Weighted Range Sum Queries Hard Two Pointers Python Explanation
4127 Maximum Billboard Revenue Medium Tree & Graph Python Explanation
4126 Count Valid K-Distance Strings Medium Tree & Graph Python Explanation
4125 Find the Mirror Exception Easy Array / General Python Explanation
4123 Minimum Cost to Delete Array Hard Array / General Python Explanation
4122 Earliest Signal Activation Times Medium Array / General Python Explanation
4121 Minimum Cost to Make All Array Elements Equal Medium Array / General Python Explanation
4120 Count Dominant Elements Easy Two Pointers Python Explanation
4119 Minimum Set Bits in a Valid Integer Hard Bit Manipulation Python Explanation
4118 Minimum Operations to Make Mountain Array I Medium Two Pointers Python Explanation
4117 Minimum Range After Sum Operations Medium Array / General Python Explanation
4116 Assign Umbrella on Rainy Days Easy Two Pointers Python Explanation
4114 Count Consistent Subarrays II Hard Two Pointers Python Explanation
4113 Game of Divisible Sums Medium Dynamic Programming Python Explanation
4112 Maximize Score After Zeroing Subtrees Medium Two Pointers Python Explanation

Navigation & Topic Hubs

1. By Pattern (Browse All Patterns)

2. By Algorithm (Browse All Algorithms)

3. By Data Structure (Browse All Data Structures)

4. By Difficulty (Browse All Difficulties)

5. By Programming Language (Browse All Languages)

6. By Problem Range (Directory Buckets)


Complete Problem Directory

Browse the full index of all solved problems in All_Problems.md.


Repository Architecture

AlbinMath/leetcode
├── README.md
├── All_Problems.md
├── patterns/             # Categorized pattern hubs
├── algorithms/           # Algorithm index hubs
├── data-structures/      # Data structure index hubs
├── difficulty/           # Easy, Medium, Hard hubs
├── languages/            # Language-specific hubs
├── metadata/             # problems.json dataset
├── scripts/              # Automation scripts
└── leetcode/             # Range-partitioned problem directories
    ├── README.md         # Directory index & navigation
    ├── 0001-0500/        # Problems 1 - 500
    ├── 0501-1000/        # Problems 501 - 1000
    ├── 1001-1500/        # Problems 1001 - 1500
    ├── 1501-2000/        # Problems 1501 - 2000
    ├── 2001-2500/        # Problems 2001 - 2500
    ├── 2501-3000/        # Problems 2501 - 3000
    ├── 3001-3500/        # Problems 3001 - 3500
    ├── 3501-4000/        # Problems 3501 - 4000
    └── 4001-4500/        # Problems 4001 - 4500

Automation & CI/CD Pipeline

The repository utilizes a two-stage GitHub Actions automation workflow:

  1. Sync LeetCode: Runs on an hourly schedule to sync new LeetCode submissions directly into leetcode/.
  2. Generate LeetCode Indexes & Metadata: Triggered automatically upon successful completion of the sync workflow (workflow_run). It partitions new submissions into range buckets (0001-0500/, 0501-1000/, etc.), generates comprehensive Explanation.md files, updates metadata/problems.json, refreshes topic hubs, and updates README.md and All_Problems.md.

License & Repository Information

GitHub: AlbinMath/leetcode
Continuously updated as new LeetCode problems are solved.

About

LeetCode solutions, DSA algorithms, data structures, coding interview problems, and programming solutions in Python, C++, and JavaScript with explanations, complexity analysis, and optimized approaches. Continuously updated.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages