Python stdlib functions to calculate GCD (greatest common divisor) and LCM (lowest common multiple)

Python standard library's math module provides functions to calculate gcd math.gcd and lcm math.lcm.