# candida18/hospital-management-system architecture

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

- Interactive diagram: https://gitdiagram.com/candida18/hospital-management-system
- Repository: https://github.com/candida18/hospital-management-system

## Overview

This is a small command-line hospital patient-record program. The principal workflow is selecting a menu action to add, find, delete, count, or display patient records held in an in-memory linked list. The README only names the project; the sampled C source supports these operations, but omitted lines limit certainty about some function details.

Main entry points: [`Application.c`](https://github.com/candida18/hospital-management-system/blob/main/Application.c) (Menu loop)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_user(("User"))
node_menu["Menu loop<br/>[Application.c]"]
node_records["Patient list<br/>[Application.c]"]
node_insert["Insert record<br/>[Application.c]"]
node_search["Search record<br/>[Application.c]"]
node_delete["Delete record<br/>[Application.c]"]
node_count["Count patients<br/>[Application.c]"]
node_display["Display records<br/>[Application.c]"]
node_terminal(("Terminal"))

node_user -->|"selects action"| node_menu
node_menu -->|"calls"| node_insert
node_menu -->|"calls"| node_search
node_menu -->|"calls"| node_delete
node_menu -->|"calls"| node_count
node_menu -->|"calls"| node_display
node_insert -->|"appends record"| node_records
node_search -->|"scans"| node_records
node_delete -->|"updates list"| node_records
node_count -->|"traverses"| node_records
node_display -->|"traverses"| node_records
node_menu -->|"prompts and reports"| node_terminal
node_search -->|"prints match"| node_terminal
node_display -->|"prints records"| node_terminal

click node_menu "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_records "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_insert "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_search "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_delete "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_count "https://github.com/candida18/hospital-management-system/blob/main/Application.c"
click node_display "https://github.com/candida18/hospital-management-system/blob/main/Application.c"

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_user toneBlue
class node_menu,node_records,node_insert,node_search,node_delete,node_count,node_display toneTeal
class node_terminal toneIndigo
```

## Components

### Other components

- **User**
- [Menu loop](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Patient list](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Insert record](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Search record](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Delete record](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Count patients](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- [Display records](https://github.com/candida18/hospital-management-system/blob/main/Application.c): `Application.c`
- **Terminal**

## Connections

- User → Menu loop: selects action
- Menu loop → Insert record: calls
- Menu loop → Search record: calls
- Menu loop → Delete record: calls
- Menu loop → Count patients: calls
- Menu loop → Display records: calls
- Insert record → Patient list: appends record
- Search record → Patient list: scans
- Delete record → Patient list: updates list
- Count patients → Patient list: traverses
- Display records → Patient list: traverses
- Menu loop → Terminal: prompts and reports
- Search record → Terminal: prints match
- Display records → Terminal: prints records
