**Tell us what’s happening:**

Ok, so this isn’t really in regards to the code so much as understanding HOW and WHY we would get to the conclusion of needing (myMax - myMin + 1)) + myMin ???

I’m just confused how it got there and the instructions didn’t help me make sense of this. Is this just some formula I’m meant to memorize? Was I meant to come to this conclusion naturally?? This is the second code I have just copied the instruction code directly and gotten the right answer, but not actually understood what was going on.

From the challenge:

"Here’s the formula we’ll use. **Take a moment to read it and try to understand what this code is doing**:

Math.floor(Math.random() * (max - min + 1)) + min"

I don’t under stand ** what this code is doing**.

Thank you in advance for any help

**Your code so far**

```
// Example
function ourRandomRange(ourMin, ourMax) {
return Math.floor(Math.random() * (ourMax - ourMin + 1)) + ourMin;
}
ourRandomRange(1, 9);
// Only change code below this line.
function randomRange(myMin, myMax) {
return Math.floor(Math.random() * (myMax - myMin + 1)) + myMin; // Change this line
}
// Change these values to test your function
var myRandom = randomRange(5, 15);
```

**Your browser information:**

Your Browser User Agent is: `Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36`

.

**Link to the challenge:**