This 5 ECTS course in Algorithms at Åbo Akademi taught me the basics of algorithms. It contained five different projects:
Maze Generator with GUI: This Java program generates and visually displays a randomly constructed maze using Union-Find with path compression and union by rank to ensure all cells are connected. It uses Swing to render a grid-based maze of configurable size, with a graphical interface highlighting the entrance and exit.
Graph Cycle Finder: This Java program reads a graph description from a file using a GUI file chooser, builds the graph as an adjacency list of Vertex objects, and performs a topological sort to determine a valid ordering of nodes. It detects cycles and handles file format errors, with the main logic split between the ReadFile class and a supporting Vertex class that tracks node names, in-degrees, and neighbors.
Vertex: This Java program reads a list of words from a file and represents them as vertices in a graph, where edges are automatically created between words that differ by one letter. It then allows the user to interactively search for the shortest path between two words using breadth-first search (BFS), effectively solving a classic "word ladder" problem.
Alphabetisation: This Java program reads a text file of words, sorts them using three different algorithms—Insertion Sort, Merge Sort, and Quick Sort (with median-of-three and insertion sort fallback)—and measures the execution time of each. It writes the sorted results to separate output files for performance comparison and benchmarking.
Tic Tac Toe Game with GUI: This Tic Tac Toe AI uses the Minimax algorithm to simulate all possible moves and choose the one that guarantees the best outcome for the computer. By evaluating win, loss, and draw scenarios recursively, it ensures the AI is unbeatable.