Computer Science Coursework
CPSC 221 Graphs and Union-Find Lab
A UBC CPSC 221 C++ graph lab with graph.cpp, graph_tools.cpp, edge structures, premade graph utilities, tests, and disjoint-set files. It focuses on representation, connectivity, weighted edges, and union-find reasoning.
Period
Mar 2025
Tools / Tech
C++GraphsGraph AlgorithmsUnion-FindDisjoint SetsWeighted Edges
Why I built it
The lab helped connect graph algorithms to implementation details such as edge storage, connectivity checks, and disjoint-set updates.
Links
What it includes
- Works with graph representation files, edge structures, and graph tools.
- Uses disjoint-set data structures for connectivity-oriented reasoning.
- Includes tests and demo files for checking graph behavior.
What I worked on
- Completed the graph and disjoint-set implementation work myself in C++.
- Practiced debugging behavior across multiple supporting files.
- Kept the description grounded in algorithms and data structures rather than product features.
What I Learned
- Learned how graph correctness depends on representation choices.
- Practiced union-find reasoning for connectivity-style problems.
- Improved ability to trace algorithm behavior across related C++ modules.