4 ms·
This seems to use an external random number generator. I want the code to be complete and reproducible. So gimmeTheNumberAtPosition(x) will always return the s
by TekMol 6y ago
This seems to use an external random number generator.
I want the code to be complete and reproducible. So gimmeTheNumberAtPosition(x) will always return the same for the same x.
Also, FYShuffle is much more complex than I would like the algo to be.
- jimktrains2 6y agoIf you seed your random number generator, then it is reproducible.
- jhgb 6y agoFisher-Yates is one of the simplest things out there IMO. Isn't the Lehmer code the thing that you want? Then you can specify your permutation with an integer and extract the individual digits from it repeatedly.
- deleted 6y ago[deleted]
- miked85 6y agoAre you saying you want a reproducible random number generator?