Update lcm.md

This commit is contained in:
Rohit Tanwar
2018-01-09 01:34:51 +05:30
committed by GitHub
parent be413ad13c
commit 90f99dbe0f

View File

@ -2,7 +2,7 @@
Returns the least common multiple of two or more numbers.
Use the greatest common divisor (GCD) formula and `Math.abs()` to determine the least common multiple.
Use the greatest common divisor (GCD) formula and the fact that `lcm(x,y) = x * y / gcd(x,y)` to determine the least common multiple.
The GCD formula uses recursion.
```js