Exploring Abstract Algebraic Structures in Swift