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: examples/RandomNumbers/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ However, functions in Roc are guaranteed to return the same answer when given th
9
9
But this also means something like `Math.random` couldn’t possibly be a valid Roc function!
10
10
So, we use a different approach to generate random numbers in Roc.
11
11
12
-
This example uses a `Generator` which generates pseudorandom numbers using an initial seed value and the [PCG algorithm](https://www.pcg-random.org/).
12
+
This example uses a `Generator` which generates pseudorandom numbers using an initial seed value and the [PCG algorithm](https://en.wikipedia.org/wiki/Permuted_congruential_generator).
13
13
If the same seed is provided, then the same number sequence will be generated every time!
14
14
The appearance of randomness comes entirely from deterministic math being done on that initial seed.
15
15
The same is true of `Math.random()`, except that `Math.random()` silently chooses a seed for you at runtime.
0 commit comments