Skip to content

Commit 7a2b695

Browse files
committed
demonstrating precisely what's included and what's excluded.
1 parent 0dfa642 commit 7a2b695

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Sprint-1/1-key-exercises/4-random.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ const num = Math.floor(Math.random() * (maximum - minimum + 1)) + minimum;
1111
// the num represents a value with limited interval and that's why
1212
// the num assigned to a value that's in the dor of an expression
1313
// the math object is invoked to perform some mathematical tasks
14-
// the random method is invoked to get a random number between 0 and 1
14+
// the random method is invoked to get a random number between 0 (inclusive) and 1 (exclusive)
1515
// the random number is multiplied by 100
1616
// the floor method is invoked to round down the result to its nearest integer
17-
// added one to the new result
17+
// added one to the new result
1818
// the final result of the whole expression is what the variable num assigned to
1919
/* after applying the program several times, I got the idea that the program is generating
20-
a value to the num variable thats always between minimum an maximum*/
20+
a value to the num variable thats always between minimum wich is number 1 (included) and maximum wich is number 100 (included) */

0 commit comments

Comments
 (0)