Mid Coding

Least Common Multiple (LCM)?

int LCM(int a, int b)

return a / GCD(a, b) * b;

Explanation:

LCM × GCD = product of the two numbers.

More from C# Programming Tutorial

All questions for this course