# tteichma/aoc-2023 architecture

> Architecture diagram of the GitHub repository tteichma/aoc-2023, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tteichma/aoc-2023
- Repository: https://github.com/tteichma/aoc-2023

## Overview

##### Main Components

a) Core Solution Structure:
- Solution Runner/Entry Point
- Daily Problem Modules (Day01-Day25)
- Utility Modules (MapUtils, MathUtils, Utils)

b) Build System:
- Gradle Build System
- Kotlin Compiler

**┌─────────────────────────────────────────────┐**
- Solution Runner                 │
- ┤

- Daily Problem Modules             │
- ┌─────┐ ┌─────┐ ┌─────┐       ┌─────┐    │
- Day01│ │Day02│ │Day03│ • • • │Day25│    │
- ┘ └─────┘ └─────┘       └─────┘    │

- ┤
- Utility Layer                     │
- ┌────────┐  ┌─────────┐  ┌───────┐       │
- MapUtils│  │MathUtils│  │Utils  │       │
- ┘  └─────────┘  └───────┘       │
- ┤
- Build System                      │
- ┌────────────────┐  ┌──────────────────┐  │
- Gradle Build    │  │Kotlin Compiler   │  │
- ┘  └──────────────────┘  │
- ┘

##### Key Relationships

- Daily Problem Modules depend on Utility Modules
- Solution Runner coordinates execution of Daily Problem Modules
- Build System processes all Kotlin source files

##### Important Details

a) Component Labels:
- Clear version numbers for Gradle and Kotlin
- Explicit naming of utility modules and their purposes
- Day numbers for problem modules

b) Interaction Flows:
- Input processing flow
- Solution computation flow
- Output generation flow

## Diagram (Mermaid)

```mermaid
flowchart TB
    subgraph "Solution Runner Layer"
        SR[Solution Runner]
    end

    subgraph "Daily Problem Modules"
        D01[Day01]:::daily
        D02[Day02]:::daily
        D03[Day03]:::daily
        DXX["..."]:::daily
        D25[Day25]:::daily
        DT[Problem Template]:::template
    end

    subgraph "Utility Layer"
        MU[MapUtils]:::util
        MTU[MathUtils]:::util
        U[Utils]:::util
    end

    subgraph "Build System"
        GB[Gradle Build]:::build
        GW[Gradle Wrapper]:::build
        GP[Gradle Properties]:::build
        GS[Gradle Settings]:::build
        KC[Kotlin Compiler]:::build
    end

    %% Relationships
    SR --> D01
    SR --> D02
    SR --> D03
    SR --> DXX
    SR --> D25

    D01 --> MU
    D01 --> MTU
    D01 --> U
    D02 --> MU
    D02 --> MTU
    D02 --> U
    D03 --> MU
    D03 --> MTU
    D03 --> U
    D25 --> MU
    D25 --> MTU
    D25 --> U

    GB --> KC
    GW --> GB
    GP --> GB
    GS --> GB
    KC --> SR

    %% Click Events
    click D01 "https://github.com/tteichma/aoc-2023/blob/main/src/Day01.kt"
    click D02 "https://github.com/tteichma/aoc-2023/blob/main/src/Day02.kt"
    click D03 "https://github.com/tteichma/aoc-2023/blob/main/src/Day03.kt"
    click D25 "https://github.com/tteichma/aoc-2023/blob/main/src/Day25.kt"
    click DT "https://github.com/tteichma/aoc-2023/blob/main/src/DayXX.kt"
    click MU "https://github.com/tteichma/aoc-2023/blob/main/src/MapUtils.kt"
    click MTU "https://github.com/tteichma/aoc-2023/blob/main/src/MathUtils.kt"
    click U "https://github.com/tteichma/aoc-2023/blob/main/src/Utils.kt"
    click GB "https://github.com/tteichma/aoc-2023/blob/main/build.gradle.kts"
    click GW "https://github.com/tteichma/aoc-2023/blob/main/gradle/wrapper/gradle-wrapper.jar"
    click GP "https://github.com/tteichma/aoc-2023/blob/main/gradle/wrapper/gradle-wrapper.properties"
    click GS "https://github.com/tteichma/aoc-2023/blob/main/settings.gradle.kts"

    %% Styles
    classDef daily fill:#90EE90,stroke:#333,stroke-width:2px
    classDef template fill:#FFB6C1,stroke:#333,stroke-width:2px
    classDef util fill:#FFE4B5,stroke:#333,stroke-width:2px
    classDef build fill:#D3D3D3,stroke:#333,stroke-width:2px

    %% Legend
    subgraph Legend
        L1[Daily Solutions]:::daily
        L2[Template]:::template
        L3[Utilities]:::util
        L4[Build Components]:::build
    end
```
