How abdullatech06/leetcode works
1. This repository is a collection of independent LeetCode solutions, not a single integrated application. The core architectural unit is a problem folder named with the LeetCode ID and slug, such as 0146-lru-cache or 0778-swim-in-rising-water.
2. Each problem folder is self-contained and typically contains exactly two artifacts: a C++ source file with the solution implementation and a folder-level README.md describing that specific problem. There is no visible shared library, common utility layer, or cross-problem code reuse.
3. The root-level README.md acts as the catalog and navigation layer. It aggregates all solutions into topic indexes like Array, Dynamic Programming, Graph Theory, Tree, Heap, Sliding Window, and so on. This README is the main architectural map of the repository.
4. The codebase is organized around algorithmic problem domains rather than product features. The folder taxonomy reflects the solution strategy boundaries: for example, graph-related problems are grouped under graph theory, tree problems under binary tree/BST/tree, and sequence problems under sliding window, prefix sum, or monotonic stack.
5. The runtime model is simple: each C++ file is meant to be submitted to the LeetCode judge as an isolated program fragment. Inputs come from LeetCode’s online judge, the solution computes locally within the problem file, and the output is returned directly to the judge. There is no separate service layer, persistence layer, or API boundary inside the repo.
6. The repository therefore has a very strong isolation boundary per problem. State is only local to a solution file or its helper types, such as linked-list nodes, tree nodes, cache objects, or graph representations. Nothing in one problem folder depends on another folder’s implementation.
7. Several problem folders correspond to classic “design” or “data stream” components like LRU Cache, LFU Cache, Median from Data Stream, Design Twitter, Min Stack, and Kth Largest in a Stream. These act like in-memory object models with method-based interaction, but they are still packaged as standalone LeetCode solutions rather than reusable infrastructure.
8. Many tree, graph, and linked-list problems imply explicit internal data structures: trees, adjacency lists, queues, stacks, heaps, union-find sets, and dynamic programming tables. Architecturally, these are implementation patterns inside problem modules, not standalone subsystems exposed across the repo.
9. The repository has no visible build orchestration, package manager, CI pipeline, or test harness in the provided tree. That suggests the main workflow is authoring solution files and reading problem-specific READMEs, then submitting code directly to LeetCode.
10. The naming convention is consistent and important for navigation: zero-padded numeric IDs preserve problem order and make topic indexing deterministic. This convention is the primary organizing mechanism for the repo’s “module registry.”
11. From a diagram perspective, the most accurate high-level view is: Root README as index, many independent problem folders as leaf modules, and LeetCode as the external execution environment. There is no central runtime, no shared backend, and no cross-module data flow between solutions.
12. If you need to draw boundaries, the natural boundary is at the folder level: each folder encloses one solution, one problem statement context, and one judge contract. The root only provides documentation and categorization.
Main entry points: README.md README.md · 0102-binary-tree-level-order-traversal/README.md Level Order · 0207-course-schedule/README.md Course Schedule · 0743-network-delay-time/README.md Network Delay
Components 27
Documentation
Repository navigation and catalog layer
- README.md · Root topic map and repository navigation hub
README.md
Arrays & Strings
Core sequence problems over arrays, strings, and greedy patterns
- Array/String · Large catalog of array, string, interval, and sliding-window solutions
- Patterns · Two-pointer, monotonic stack, prefix sum, and greedy sequence patterns
- Trapping Water · Representative array/two-pointer style solution
0042-trapping-rain-water/README.md - Window Max · Representative deque-based window processing module
0239-sliding-window-maximum/README.md - Merge Intervals · Representative interval normalization and sweep-style solution
0056-merge-intervals/README.md
Linked Structures
Linked lists and stateful design objects
- Linked Lists · Standalone linked-list manipulations and cache-style objects
Trees
Binary tree and BST modules
- Trees · Traversal, construction, query, and serialization problems on trees
- Level Order · Representative binary-tree traversal module
0102-binary-tree-level-order-traversal/README.md - LCA Tree · Representative tree recursion and ancestor query module
0236-lowest-common-ancestor-of-a-binary-tree/README.md - Serialize Tree · Representative tree serialization and deserialization module
0297-serialize-and-deserialize-binary-tree/README.md
Graphs
Connectivity, shortest path, and graph search modules
- Graphs · Traversal, connectivity, and shortest-path problems on graphs and grids
- Course Schedule · Representative dependency-graph traversal and ordering module
0207-course-schedule/README.md - Network Delay · Representative weighted shortest-path module
0743-network-delay-time/README.md - Critical Connections · Representative low-link connectivity analysis module
1192-critical-connections-in-a-network/README.md
DP & Search
Dynamic programming, recursion, and combinatorics-heavy problems
- DP/Backtrack · Dynamic programming, recursion, and search-heavy problem families
- Combination Sum · Representative search and combination-generation module
0039-combination-sum/README.md - Coin Change · Representative dynamic programming module
0322-coin-change/README.md - LCS · Representative sequence dynamic programming module
1143-longest-common-subsequence/README.md
Math & Bits
Numeric, bitwise, and other standalone algorithms
- Math/Bit · Bit manipulation, number theory, and smaller standalone algorithms
- Reverse Bits · Representative bit-manipulation module
0190-reverse-bits/README.md - Count Primes · Representative numeric counting and sieve module
0204-count-primes/README.md
Streaming DS
In-memory data structure design and stream-style problems
- Design/Stream · Stateful object-model problems and streaming data structures
- LRU Cache · Representative in-memory cache object with method-based interaction
0146-lru-cache/README.md - Design Twitter · Representative stateful object model packaged as an isolated judge submission
0355-design-twitter/README.md - Median Stream · Representative streaming aggregation with heaps
0295-find-median-from-data-stream/README.md
Other components
- LeetCode · External online judge that runs each solution in isolation
Connections 34
- README.md → Array/String: indexes · Catalogs array and string problems
- README.md → Patterns: indexes · Catalogs sequence patterns like sliding window and intervals
- README.md → Linked Lists: indexes · Catalogs linked-list and design problems
- README.md → Trees: indexes · Catalogs tree and BST problems
- README.md → Graphs: indexes · Catalogs graph problems
- README.md → DP/Backtrack: indexes · Catalogs dynamic programming and backtracking problems
- README.md → Math/Bit: indexes · Catalogs math and bit-manipulation problems
- README.md → Design/Stream: indexes · Catalogs design and streaming data-structure problems
- Array/String → Trapping Water: example · Representative array problem
- Array/String → Window Max: example · Representative sliding-window problem
- Array/String → Merge Intervals: example · Representative interval problem
- Linked Lists → LRU Cache: example · Representative cache design problem
- Linked Lists → Design Twitter: example · Representative stateful design problem
- Linked Lists → Median Stream: example · Representative streaming structure problem
- Trees → Level Order: example · Representative tree traversal problem
- Trees → LCA Tree: example · Representative tree query problem
- Trees → Serialize Tree: example · Representative tree codec problem
- Graphs → Course Schedule: example · Representative graph ordering problem
- Graphs → Network Delay: example · Representative shortest-path problem
- Graphs → Critical Connections: example · Representative connectivity/bridges problem
- DP/Backtrack → Combination Sum: example · Representative backtracking/search problem
- DP/Backtrack → Coin Change: example · Representative dynamic programming problem
- DP/Backtrack → LCS: example · Representative subsequence DP problem
- Math/Bit → Reverse Bits: example · Representative bit-manipulation problem
- Math/Bit → Count Primes: example · Representative sieve/counting problem
- README.md → LeetCode: submits to · Solutions are authored for isolated judge execution
- LRU Cache → LeetCode: runs on · LeetCode executes each problem file independently
- Design Twitter → LeetCode: runs on · LeetCode executes each problem file independently
- Median Stream → LeetCode: runs on · LeetCode executes each problem file independently
- Level Order → LeetCode: runs on · LeetCode executes each problem file independently
- Course Schedule → LeetCode: runs on · LeetCode executes each problem file independently
- Network Delay → LeetCode: runs on · LeetCode executes each problem file independently
- Combination Sum → LeetCode: runs on · LeetCode executes each problem file independently
- Reverse Bits → LeetCode: runs on · LeetCode executes each problem file independently