**Tell us what’s happening:**

this is the answer i got by googling how to get the smallest common mulitple

i basically copied it thinking i understood it but it doesnt make no sense to me please can someone point me to some material thast can help me understand this sort of algorithm

**Your code so far**

```
function smallestCommons(arr) {
let max = Math.max(arr[0], arr[1]);
let min = Math.min(arr[0], arr[1]);
let range = [];
for (let i = min; i <= max; i++){
range.push(i);
}
// i understand up to here!
let a = range[0];
for (let i = 1; i < range.length; i++){
let b = range[i];
let c = a;
while ( a && b){
if (a > b){
a %= b;
}else{
b %= a;
}
}
a = c * range[i] / (a+b);
}
return a
}
// this ^^^^^ confuses me big time!!!!!!!!!
console.log(smallestCommons([1,3]));
```

**Your browser information:**

User Agent is: `Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Safari/537.36`

.

**Challenge:** Smallest Common Multiple

**Link to the challenge:**