# xuej41/cpp-projects architecture

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

- Interactive diagram: https://gitdiagram.com/xuej41/cpp-projects
- Repository: https://github.com/xuej41/cpp-projects

## Overview

##### Main Components

a. Project Categories
- Laboratory Assignments (Lab0-Lab4)
- Programming Practice Assignments (PPA1-PPA3)
- Competitive Programming Solutions (DMOJ_CP_Questions)
- Course Project (Final_Course_Project)

b. Key Architectural Patterns
- Each lab/assignment follows a consistent structure with testing frameworks
- Modular design with separate header (.h) and implementation (.cpp/.c) files
- Automated testing infrastructure (GitHub Classroom integration)

##### Educational Labs Section
- Labs 0-4 as individual modules
- Each lab should have connections to:
- Source files (Questions.c/h)
- Test infrastructure (testCases.c)
- Build system (makefile)
- Automation (.github/classroom)

##### Programming Practice Assignments Section
- PPA1-3 modules
- Common components:
- MacUILib (shared library)
- Main implementation files
- Build configuration

##### Final Course Project Section
- Game architecture:
- Core Components (GameMechs, Player)
- UI Layer (MacUILib)
- Object Management (objPos, objPosArrayList)
- Test Suite connection

##### Competitive Programming Section
- Solutions by algorithm type:
- Graph Algorithms (BFS, DFS)
- Data Structures (Segment Trees, Bitset)
- Contest Solutions (CCC)

##### Important Details to Capture

- GitHub Classroom Integration:
- Automation workflow
- Autograding configuration
- Test case execution flow

- Build System:
- Makefile relationships
- Compilation dependencies
- Test execution paths

- Common Libraries:
- MacUILib usage across PPAs
- Shared utility functions
- Testing frameworks

Level 1 (Top): Main project categories
Level 2: Individual projects/assignments
Level 3: Component files and relationships
Level 4 (Bottom): File-level dependencies

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Legend
        L1[Source Files]:::source
        L2[Header Files]:::header
        L3[Test Components]:::test
        L4[Build Files]:::build
        L5[Main Categories]:::category
    end

    subgraph Labs["Laboratory Assignments"]
        Labs_Main["Labs Infrastructure"]:::category
        click Labs_Main "https://github.com/xuej41/cpp-projects/tree/main/Lab0"
        
        TestFramework["Testing Framework"]:::test
        click TestFramework "https://github.com/xuej41/cpp-projects/blob/main/Lab0/testCases.c"
        
        GHAutomation["GitHub Automation"]:::build
        click GHAutomation "https://github.com/xuej41/cpp-projects/blob/main/Lab0/.github/classroom/autograding.json"
        
        LabBuild["Lab Build System"]:::build
        click LabBuild "https://github.com/xuej41/cpp-projects/tree/main/Lab0/makefile"
        
        Labs_Main --> TestFramework
        Labs_Main --> GHAutomation
        Labs_Main --> LabBuild
    end

    subgraph PPAs["Programming Practice Assignments"]
        PPA_Main["PPA Infrastructure"]:::category
        
        MacUILib_H["MacUILib Header"]:::header
        click MacUILib_H "https://github.com/xuej41/cpp-projects/blob/main/PPA1/MacUILib.h"
        
        MacUILib_C["MacUILib Implementation"]:::source
        click MacUILib_C "https://github.com/xuej41/cpp-projects/blob/main/PPA1/MacUILib.c"
        
        StringLib_H["String Library Header"]:::header
        click StringLib_H "https://github.com/xuej41/cpp-projects/blob/main/PPA3/myStringLib.h"
        
        StringLib_C["String Library Implementation"]:::source
        click StringLib_C "https://github.com/xuej41/cpp-projects/blob/main/PPA3/myStringLib.c"
        
        PPA_Impl["PPA Implementations"]:::source
        click PPA_Impl "https://github.com/xuej41/cpp-projects/blob/main/PPA1/PPA1.c"
        
        PPA_Build["PPA Build System"]:::build
        click PPA_Build "https://github.com/xuej41/cpp-projects/tree/main/PPA1/makefile"
        
        PPA_Main --> MacUILib_H & MacUILib_C
        PPA_Main --> StringLib_H & StringLib_C
        PPA_Main --> PPA_Impl
        PPA_Main --> PPA_Build
    end

    subgraph FinalProject["Final Course Project"]
        Project_Main["Game Architecture"]:::category
        click Project_Main "https://github.com/xuej41/cpp-projects/tree/main/Final_Course_Project"
        
        GameMechs_H["GameMechs Header"]:::header
        click GameMechs_H "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/GameMechs.h"
        
        GameMechs_CPP["GameMechs Implementation"]:::source
        click GameMechs_CPP "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/GameMechs.cpp"
        
        Player_H["Player Header"]:::header
        click Player_H "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/Player.h"
        
        Player_CPP["Player Implementation"]:::source
        click Player_CPP "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/Player.cpp"
        
        ObjPos_H["Object Position Header"]:::header
        click ObjPos_H "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/objPos.h"
        
        ObjPosArray_H["Object Array Header"]:::header
        click ObjPosArray_H "https://github.com/xuej41/cpp-projects/blob/main/Final_Course_Project/objPosArrayList.h"
        
        TestSuite["Test Suite"]:::test
        click TestSuite "https://github.com/xuej41/cpp-projects/tree/main/Final_Course_Project/objPosArrayList_TestSuite"
        
        Project_Build["Project Build System"]:::build
        click Project_Build "https://github.com/xuej41/cpp-projects/tree/main/Final_Course_Project/makefile"
        
        Project_Main --> GameMechs_H & GameMechs_CPP
        Project_Main --> Player_H & Player_CPP
        Project_Main --> ObjPos_H & ObjPosArray_H
        Project_Main --> TestSuite
        Project_Main --> Project_Build
    end

    subgraph CP["Competitive Programming"]
        CP_Main["CP Solutions"]:::category
        click CP_Main "https://github.com/xuej41/cpp-projects/tree/main/DMOJ_CP_Questions"
        
        GraphAlgo["Graph Algorithms"]:::source
        click GraphAlgo "https://github.com/xuej41/cpp-projects/blob/main/DMOJ_CP_Questions/BFS.cpp"
        
        DataStructures["Data Structures"]:::source
        click DataStructures "https://github.com/xuej41/cpp-projects/blob/main/DMOJ_CP_Questions/SegmentTree_range_max_&_update_Iterative.cpp"
        
        ContestSol["Contest Solutions"]:::source
        click ContestSol "https://github.com/xuej41/cpp-projects/blob/main/DMOJ_CP_Questions/CCC_18_S5_MaximumStrategicSavings.cpp"
        
        CP_Main --> GraphAlgo
        CP_Main --> DataStructures
        CP_Main --> ContestSol
    end

    classDef category fill:#blue,stroke:#333,stroke-width:2px
    classDef source fill:#90EE90,stroke:#333,stroke-width:2px
    classDef header fill:#FFD700,stroke:#333,stroke-width:2px
    classDef test fill:#FF6B6B,stroke:#333,stroke-width:2px
    classDef build fill:#808080,stroke:#333,stroke-width:2px
```
