# errichto/youtube architecture

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

- Interactive diagram: https://gitdiagram.com/errichto/youtube
- Repository: https://github.com/errichto/youtube

## Overview

##### Project type and purpose
- This repository is not a traditional client-server or full-stack application.
- It’s a curated collection of standalone algorithmic solutions organized by contest or problem set (Advent of Code, Google Code Jam, POI, LeetCode, etc.).
- Its purpose is to store, organize, and share code templates, solutions, input files, and small helper scripts for programming contests.

##### File structure
- Top-level directories each represent a “module” or contest category (e.g., AOC-2020, AOC-2024, GCJ, leetcode, atcoder-dp, hashcode, POI, PSUT-coding-marathon, etc.).
- Within each module are problem-specific source files (*.cpp, *.py), input files (in/), and sometimes visualizers or interactive runners.
- A common “templates” directory provides reusable code snippets (geo.cpp, gp_hash_table.cpp, ordered_set.cpp).
- A “testing” directory houses test harnesses, generators, and scripts (gen.cpp, s.sh).
- A few modules include specialized scripts (interactive_runner.py, testing_tool.py, s.sh) to automate compilation and testing.
- There is no single build script or CI config, as each solution compiles and runs independently.

##### README
- The README currently only contains “429: Too Many Requests,” which appears to be a placeholder or error message.

##### Detail and clarity
- Every contest folder as its own component to reflect the repository layout.
- How shared code (templates) and scripts interact with individual solutions.
- Don’t overthink interactions that don’t exist—focus on compile-time and test-time flows rather than runtime services.

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Contest Modules
    subgraph "Contest Modules"
        direction TB
        AOC2020["AOC-2020"]:::contest
        AOC2024["AOC-2024"]:::contest
        GCJ["GCJ"]:::contest
        POI["POI"]:::contest
        PSUT["PSUT-coding-marathon"]:::contest
        LeetCode["leetcode"]:::contest
        AtCoderDP["atcoder-dp"]:::contest
        HashCode["hashcode"]:::contest
        Codeforces["codeforces"]:::contest
        AndReach["and-reachability"]:::contest
        MatrixExp["matrix-exponentiation"]:::contest
        PaintingFence["painting-the-fence"]:::contest
        Pairs["pairs"]:::contest
        PartitionPerm["partition-into-permutations"]:::contest
        TwoArrays["two-arrays-and-sum-of-functions"]:::contest
    end

    %% Shared Resources
    subgraph "Shared Resources"
        direction TB
        Templates["Templates"]:::shared
        Testing["Testing Tools"]:::shared
    end

    %% External Toolchain
    subgraph "External Toolchain"
        direction TB
        CPP["C++ Compiler"]:::tool
        PY["Python Interpreter"]:::tool
        SH["Shell"]:::tool
    end

    %% Relationships
    %% Each contest uses templates and testing and compilers
    AOC2020 -->|"includes templates"| Templates
    AOC2024 -->|"includes templates"| Templates
    GCJ -->|"includes templates"| Templates
    POI -->|"includes templates"| Templates
    PSUT -->|"includes templates"| Templates
    LeetCode -->|"includes templates"| Templates
    AtCoderDP -->|"includes templates"| Templates
    HashCode -->|"includes templates"| Templates
    Codeforces -->|"includes templates"| Templates
    AndReach -->|"includes templates"| Templates
    MatrixExp -->|"includes templates"| Templates
    PaintingFence -->|"includes templates"| Templates
    Pairs -->|"includes templates"| Templates
    PartitionPerm -->|"includes templates"| Templates
    TwoArrays -->|"includes templates"| Templates

    AOC2020 -->|"compile"| CPP
    AOC2024 -->|"compile"| CPP
    GCJ -->|"compile"| CPP
    POI -->|"compile"| CPP
    PSUT -->|"compile"| CPP
    LeetCode -->|"compile"| CPP
    AtCoderDP -->|"compile"| CPP
    HashCode -->|"compile"| CPP
    Codeforces -->|"compile"| CPP
    AndReach -->|"compile"| CPP
    MatrixExp -->|"compile"| CPP
    PaintingFence -->|"compile"| CPP
    Pairs -->|"compile"| CPP
    PartitionPerm -->|"compile"| CPP
    TwoArrays -->|"compile"| CPP

    %% Testing automation
    Testing -->|"runs scripts on"| AOC2020
    Testing -->|"runs scripts on"| AOC2024
    Testing -->|"runs scripts on"| GCJ
    Testing -->|"runs scripts on"| POI
    Testing -->|"runs scripts on"| PSUT
    Testing -->|"runs scripts on"| LeetCode
    Testing -->|"runs scripts on"| AtCoderDP
    Testing -->|"runs scripts on"| HashCode
    Testing -->|"runs scripts on"| Codeforces
    Testing -->|"runs scripts on"| AndReach
    Testing -->|"runs scripts on"| MatrixExp
    Testing -->|"runs scripts on"| PaintingFence
    Testing -->|"runs scripts on"| Pairs
    Testing -->|"runs scripts on"| PartitionPerm
    Testing -->|"runs scripts on"| TwoArrays

    %% Click Events
    click AOC2020 "https://github.com/errichto/youtube/tree/master//AOC-2020"
    click AOC2024 "https://github.com/errichto/youtube/tree/master//AOC-2024"
    click GCJ "https://github.com/errichto/youtube/tree/master//GCJ"
    click POI "https://github.com/errichto/youtube/tree/master//POI"
    click PSUT "https://github.com/errichto/youtube/tree/master//PSUT-coding-marathon"
    click LeetCode "https://github.com/errichto/youtube/tree/master//leetcode"
    click AtCoderDP "https://github.com/errichto/youtube/tree/master//atcoder-dp"
    click HashCode "https://github.com/errichto/youtube/tree/master//hashcode"
    click Codeforces "https://github.com/errichto/youtube/blob/master//codeforces/614a-maze-game.cpp"
    click AndReach "https://github.com/errichto/youtube/blob/master//and-reachability/ac.cpp"
    click MatrixExp "https://github.com/errichto/youtube/blob/master//matrix-exponentiation/i2.cpp"
    click PaintingFence "https://github.com/errichto/youtube/blob/master//painting-the-fence/solution1.cpp"
    click Pairs "https://github.com/errichto/youtube/blob/master//pairs/ac.cpp"
    click PartitionPerm "https://github.com/errichto/youtube/blob/master//partition-into-permutations/ac.cpp"
    click TwoArrays "https://github.com/errichto/youtube/blob/master//two-arrays-and-sum-of-functions/ac.cpp"

    click Templates "https://github.com/errichto/youtube/tree/master//templates"
    click Testing "https://github.com/errichto/youtube/tree/master//testing"

    click CPP "https://github.com/errichto/youtube/tree/master//"
    click PY "https://github.com/errichto/youtube/tree/master//"
    click SH "https://github.com/errichto/youtube/tree/master//"

    %% Styles
    classDef contest fill:#ffdddd,stroke:#aa0000,stroke-width:1px
    classDef shared fill:#ddffdd,stroke:#00aa00,stroke-width:1px
    classDef tool fill:#ddddff,stroke:#0000aa,stroke-width:1px
```
