"""
Some basic math functionalities
def modular_exponentiation(base: int, exp: int, field: int) -> int:
calculates base^exp in the gallois given gallois field
Uses iterative squaring to be able to calculate large exponents aswell.
...