You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Sprint-2/1-key-exercises/4-random.js
+1-2Lines changed: 1 addition & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,6 @@ console.log(num);
24
24
25
25
26
26
27
-
// Last operation is to add 1 to hit the maximum value (since Math.random() never quite reaches 1). This ensures all 100 numbers (1 through 100) are equally reachable.eg 39 => 40
28
-
27
+
// Last operation is to add 1 to the generated rounded figure this can be any number from 0 to 99 since the rounding is using Math.Floor and not Math.Ceil we could get a (0) => adding 1 will insure the range is between 1 and 100 i.e minimuam and maximum
0 commit comments