let lcm a b = if (a = 0) || (b = 0) then 0 else if (a mod b = 0) then a else if (b mod a = 0) then b else (a * b) / (gcd a b)