# martindch24/leetcode-problems architecture

> Architecture diagram of the GitHub repository martindch24/leetcode-problems, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/martindch24/leetcode-problems
- Repository: https://github.com/martindch24/leetcode-problems

## Overview

This is a collection of independent LeetCode Python solutions, not an integrated application. The principal workflow is: an interview learner selects a problem, invokes that problem’s `Solution` method, and receives the computed answer. The repository spans arrays, strings, graph traversal, trees, greedy methods, dynamic programming, and numerical/search techniques. Sampled files show algorithms owning their own data structures and nested helpers; there is no shared runtime, persistence layer, or repository-wide orchestrator.

Main entry points: [`79.word_search.py`](https://github.com/martindch24/leetcode-problems/blob/master/79.word_search.py) (Word Search), [`2071.maximum_number_of_tasks_you_can_assign.py`](https://github.com/martindch24/leetcode-problems/blob/master/2071.maximum_number_of_tasks_you_can_assign.py) (Task Assignment), [`704.binary_search.py`](https://github.com/martindch24/leetcode-problems/blob/master/704.binary_search.py) (Binary Search), [`35.search_insert_position.py`](https://github.com/martindch24/leetcode-problems/blob/master/35.search_insert_position.py) (Insert Position)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_arrays["Arrays &amp; Windows"]
  node_binary_search["Binary Search"]
  node_insert_position["Insert Position"]
  node_max_average["Maximum Average"]
  node_rain_water["Trapping Rain Water"]
end

subgraph group_strings["Strings &amp; Grids"]
  node_goal_parser["Goal Parser"]
  node_word_search["Word Search<br/>[79.word_search.py]"]
  node_region_average["Region Average"]
  node_regex_matching["Regex Matching"]
end

subgraph group_graphs["Graphs &amp; Traversal"]
  node_route_reorder["Route Reordering"]
  node_division_eval["Division Evaluation"]
  node_point_connection["Point Connection"]
  node_course_schedule["Course Scheduling"]
end

subgraph group_optimization["DP &amp; Optimization"]
  node_task_assignment["Task Assignment"]
  node_task_feasibility["Feasibility Check"]
  node_merge_stones["Merge Stones"]
  node_coin_change["Coin Change<br/>[322.coin_change.py]"]
  node_house_robber["House Robber"]
end

subgraph group_trees["Trees &amp; Structures"]
  node_same_tree["Same Tree<br/>[100.same_tree.py]"]
  node_symmetric_tree["Symmetric Tree"]
  node_stream_median["Stream Median"]
end

node_learner(("Interview Learner"))

node_learner -->|"invokes solution"| node_binary_search
node_binary_search -->|"returns index"| node_learner
node_learner -->|"invokes solution"| node_insert_position
node_insert_position -->|"returns position"| node_learner
node_learner -->|"invokes solution"| node_max_average
node_max_average -->|"returns average"| node_learner
node_learner -->|"invokes solution"| node_rain_water
node_rain_water -->|"returns volume"| node_learner
node_learner -->|"invokes solution"| node_goal_parser
node_goal_parser -->|"returns string"| node_learner
node_learner -->|"invokes solution"| node_word_search
node_word_search -->|"returns match"| node_learner
node_word_search -->|"calls DFS"| node_word_search
node_learner -->|"invokes solution"| node_region_average
node_region_average -->|"returns grid"| node_learner
node_learner -->|"invokes solution"| node_regex_matching
node_regex_matching -->|"returns match"| node_learner
node_learner -->|"invokes solution"| node_route_reorder
node_route_reorder -->|"returns flips"| node_learner
node_learner -->|"invokes solution"| node_division_eval
node_division_eval -->|"returns values"| node_learner
node_learner -->|"invokes solution"| node_point_connection
node_point_connection -->|"returns cost"| node_learner
node_learner -->|"invokes solution"| node_course_schedule
node_course_schedule -->|"returns ordering"| node_learner
node_learner -->|"invokes solution"| node_task_assignment
node_task_assignment -->|"checks feasibility"| node_task_feasibility
node_task_feasibility -->|"returns boolean"| node_task_assignment
node_task_assignment -->|"returns count"| node_learner
node_learner -->|"invokes solution"| node_merge_stones
node_merge_stones -->|"returns cost"| node_learner
node_learner -->|"invokes solution"| node_coin_change
node_coin_change -->|"returns count"| node_learner
node_learner -->|"invokes solution"| node_house_robber
node_house_robber -->|"returns profit"| node_learner
node_learner -->|"invokes solution"| node_same_tree
node_same_tree -->|"returns equality"| node_learner
node_learner -->|"invokes solution"| node_symmetric_tree
node_symmetric_tree -->|"returns symmetry"| node_learner
node_learner -->|"invokes solution"| node_stream_median
node_stream_median -->|"returns median"| node_learner

click node_binary_search "https://github.com/martindch24/leetcode-problems/blob/master/704.binary_search.py"
click node_insert_position "https://github.com/martindch24/leetcode-problems/blob/master/35.search_insert_position.py"
click node_max_average "https://github.com/martindch24/leetcode-problems/blob/master/643.maximum_average_subarray_i.py"
click node_rain_water "https://github.com/martindch24/leetcode-problems/blob/master/42.trapping_rain_water.py"
click node_goal_parser "https://github.com/martindch24/leetcode-problems/blob/master/1678.goal_parser_interpretation.py"
click node_word_search "https://github.com/martindch24/leetcode-problems/blob/master/79.word_search.py"
click node_region_average "https://github.com/martindch24/leetcode-problems/blob/master/3030.find_the_grid_of_region_average.py"
click node_regex_matching "https://github.com/martindch24/leetcode-problems/blob/master/10.regular_expression_matching.py"
click node_route_reorder "https://github.com/martindch24/leetcode-problems/blob/master/1466.reorder_routes_to_make_all_paths_lead_to_the_city_zero.py"
click node_division_eval "https://github.com/martindch24/leetcode-problems/blob/master/399.evaluate_division.py"
click node_point_connection "https://github.com/martindch24/leetcode-problems/blob/master/1584.min_cost_to_connect_all_points.py"
click node_course_schedule "https://github.com/martindch24/leetcode-problems/blob/master/207.course_schedule.py"
click node_task_assignment "https://github.com/martindch24/leetcode-problems/blob/master/2071.maximum_number_of_tasks_you_can_assign.py"
click node_task_feasibility "https://github.com/martindch24/leetcode-problems/blob/master/2071.maximum_number_of_tasks_you_can_assign.py"
click node_merge_stones "https://github.com/martindch24/leetcode-problems/blob/master/1000.minimum_cost_to_merge_stones.py"
click node_coin_change "https://github.com/martindch24/leetcode-problems/blob/master/322.coin_change.py"
click node_house_robber "https://github.com/martindch24/leetcode-problems/blob/master/198.house_robber.py"
click node_same_tree "https://github.com/martindch24/leetcode-problems/blob/master/100.same_tree.py"
click node_symmetric_tree "https://github.com/martindch24/leetcode-problems/blob/master/101.symmetric_tree.py"
click node_stream_median "https://github.com/martindch24/leetcode-problems/blob/master/295.find_median_from_data_stream.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_binary_search,node_insert_position,node_max_average,node_rain_water,node_learner toneBlue
class node_goal_parser,node_word_search,node_region_average,node_regex_matching toneAmber
class node_route_reorder,node_division_eval,node_point_connection,node_course_schedule toneMint
class node_task_assignment,node_task_feasibility,node_merge_stones,node_coin_change,node_house_robber toneRose
class node_same_tree,node_symmetric_tree,node_stream_median toneIndigo
```

## Components

### Arrays & Windows

- [Binary Search](https://github.com/martindch24/leetcode-problems/blob/master/704.binary_search.py): `704.binary_search.py`
- [Insert Position](https://github.com/martindch24/leetcode-problems/blob/master/35.search_insert_position.py): `35.search_insert_position.py`
- [Maximum Average](https://github.com/martindch24/leetcode-problems/blob/master/643.maximum_average_subarray_i.py): `643.maximum_average_subarray_i.py`
- [Trapping Rain Water](https://github.com/martindch24/leetcode-problems/blob/master/42.trapping_rain_water.py): `42.trapping_rain_water.py`

### Strings & Grids

- [Goal Parser](https://github.com/martindch24/leetcode-problems/blob/master/1678.goal_parser_interpretation.py): `1678.goal_parser_interpretation.py`
- [Word Search](https://github.com/martindch24/leetcode-problems/blob/master/79.word_search.py): `79.word_search.py`
- [Region Average](https://github.com/martindch24/leetcode-problems/blob/master/3030.find_the_grid_of_region_average.py): `3030.find_the_grid_of_region_average.py`
- [Regex Matching](https://github.com/martindch24/leetcode-problems/blob/master/10.regular_expression_matching.py): `10.regular_expression_matching.py`

### Graphs & Traversal

- [Route Reordering](https://github.com/martindch24/leetcode-problems/blob/master/1466.reorder_routes_to_make_all_paths_lead_to_the_city_zero.py): `1466.reorder_routes_to_make_all_paths_lead_to_the_city_zero.py`
- [Division Evaluation](https://github.com/martindch24/leetcode-problems/blob/master/399.evaluate_division.py): `399.evaluate_division.py`
- [Point Connection](https://github.com/martindch24/leetcode-problems/blob/master/1584.min_cost_to_connect_all_points.py): `1584.min_cost_to_connect_all_points.py`
- [Course Scheduling](https://github.com/martindch24/leetcode-problems/blob/master/207.course_schedule.py): `207.course_schedule.py`

### DP & Optimization

- [Task Assignment](https://github.com/martindch24/leetcode-problems/blob/master/2071.maximum_number_of_tasks_you_can_assign.py): `2071.maximum_number_of_tasks_you_can_assign.py`
- [Feasibility Check](https://github.com/martindch24/leetcode-problems/blob/master/2071.maximum_number_of_tasks_you_can_assign.py): `2071.maximum_number_of_tasks_you_can_assign.py`
- [Merge Stones](https://github.com/martindch24/leetcode-problems/blob/master/1000.minimum_cost_to_merge_stones.py): `1000.minimum_cost_to_merge_stones.py`
- [Coin Change](https://github.com/martindch24/leetcode-problems/blob/master/322.coin_change.py): `322.coin_change.py`
- [House Robber](https://github.com/martindch24/leetcode-problems/blob/master/198.house_robber.py): `198.house_robber.py`

### Trees & Structures

- [Same Tree](https://github.com/martindch24/leetcode-problems/blob/master/100.same_tree.py): `100.same_tree.py`
- [Symmetric Tree](https://github.com/martindch24/leetcode-problems/blob/master/101.symmetric_tree.py): `101.symmetric_tree.py`
- [Stream Median](https://github.com/martindch24/leetcode-problems/blob/master/295.find_median_from_data_stream.py): `295.find_median_from_data_stream.py`

### Other components

- **Interview Learner**

## Connections

- Interview Learner → Binary Search: invokes solution
- Binary Search → Interview Learner: returns index
- Interview Learner → Insert Position: invokes solution
- Insert Position → Interview Learner: returns position
- Interview Learner → Maximum Average: invokes solution
- Maximum Average → Interview Learner: returns average
- Interview Learner → Trapping Rain Water: invokes solution
- Trapping Rain Water → Interview Learner: returns volume
- Interview Learner → Goal Parser: invokes solution
- Goal Parser → Interview Learner: returns string
- Interview Learner → Word Search: invokes solution
- Word Search → Interview Learner: returns match
- Word Search → Word Search: calls DFS
- Interview Learner → Region Average: invokes solution
- Region Average → Interview Learner: returns grid
- Interview Learner → Regex Matching: invokes solution
- Regex Matching → Interview Learner: returns match
- Interview Learner → Route Reordering: invokes solution
- Route Reordering → Interview Learner: returns flips
- Interview Learner → Division Evaluation: invokes solution
- Division Evaluation → Interview Learner: returns values
- Interview Learner → Point Connection: invokes solution
- Point Connection → Interview Learner: returns cost
- Interview Learner → Course Scheduling: invokes solution
- Course Scheduling → Interview Learner: returns ordering
- Interview Learner → Task Assignment: invokes solution
- Task Assignment → Feasibility Check: checks feasibility
- Feasibility Check → Task Assignment: returns boolean
- Task Assignment → Interview Learner: returns count
- Interview Learner → Merge Stones: invokes solution
- Merge Stones → Interview Learner: returns cost
- Interview Learner → Coin Change: invokes solution
- Coin Change → Interview Learner: returns count
- Interview Learner → House Robber: invokes solution
- House Robber → Interview Learner: returns profit
- Interview Learner → Same Tree: invokes solution
- Same Tree → Interview Learner: returns equality
- Interview Learner → Symmetric Tree: invokes solution
- Symmetric Tree → Interview Learner: returns symmetry
- Interview Learner → Stream Median: invokes solution
- Stream Median → Interview Learner: returns median
