Random Number Generator
No draws yet this visit. Draws stay on this page only and are never saved or sent anywhere.
Last reviewed: 20 November 2026. Reviewed every 180 days; next review due 19 May 2027.
How to use the Random Number Generator
Need a number, a list of numbers, a dice roll, or a coin flip? This random number generator does all four, in one place, with no signup and nothing to install. Pick a mode from the tabs at the top, set the range, and draw. Every number in your range has the same chance of coming up, and the page explains exactly how the draws work, what they are good for, and what they are not good for, so you can trust the result for the job at hand.
- Single number. Enter a minimum and a maximum, then press Generate number. Both ends count: a range of 1 to 100 can return 1 or 100, and every number between has the same chance. Negative ranges work too, so -10 to 10 is a valid range, and so is a range where both ends are the same number, which always returns that number.
- List. Enter a range and how many numbers you want, up to 1,000. Leave repeats allowed, or turn on No repeats to draw each number at most once. With no repeats, the count cannot be larger than the range: asking for 6 unique numbers from 1 to 5 is impossible, and the tool says so instead of guessing. Turn on Show sorted to see the same draw in ascending order.
- Dice roller. Pick a die, d4, d6, d8, d10, d12, or d20, and how many of them, from 1 to 10, then press Roll the dice. Each die shows as its own chip, and the total appears at the top. Two six-sided dice is the classic pair for board games, and a single d20 is the standard roll for tabletop role-playing games.
- Coin flip. Pick how many flips, from 1 to 10, then press Flip the coin. Each flip is a fair 50-50 call, and the result shows every flip in order plus the heads and tails counts. One flip settles a decision; ten flips show how streaks happen even on a fair coin.
- Seed (optional). Leave the seed blank for a fresh draw every time. Enter a whole number as the seed to repeat the same draw exactly: seed 42 on a 1 to 100 single draw always returns 61. Seeds are useful when you want to replay a draw, share a draw with someone else so they can check it, or test the tool. The seed box works the same way in all four modes.
- Copy results and history. The Copy results button copies the latest draw as plain text, ready to paste into a message, a document, or a spreadsheet. The Recent draws strip below the tool keeps your last 10 draws for this visit, newest first, with a Clear button. Draws stay on the page only: nothing is saved, nothing is sent anywhere, and closing the page clears them.
If the tool shows an error, it is telling you the draw cannot be done as entered: the minimum is larger than the maximum, the count is outside 1 to 1,000, a no-repeat count is larger than the range, or a die or flip count is outside its limit. Fix the number it names and draw again.
How it works
Every draw on this page starts from one random fraction between 0 and 1, then scales it to your range. The formula for an integer between a minimum and a maximum, both inclusive, is: minimum plus the whole-number part of the fraction times the size of the range. The size of the range is the maximum minus the minimum plus 1, because both ends count. For a range of 1 to 100, the size is 100, so the formula is 1 plus the whole-number part of the fraction times 100. A fraction of 0.6011 gives 1 plus 60, which is 61. This is the same inclusive formula MDN documents for JavaScript random integers, and it is the standard way to turn a uniform fraction into a uniform integer.
Two things about that formula matter. First, the whole-number part, the floor, is what keeps the distribution even: every integer gets an equal slice of the fraction range, each slice exactly 1 divided by the range size wide. Second, the maximum is reachable: a fraction just below 1 maps to the top of the range. A tempting shortcut, rounding the scaled fraction instead of taking its floor, breaks the evenness, because the top and bottom numbers then get only half a slice each. MDN warns about exactly this mistake, and this tool does not make it.
Where does the fraction come from? It depends on the seed box. With the seed blank, the fraction comes from the browser's built-in Math.random, which is a pseudorandom generator the browser seeds itself and which you cannot choose or reset. With a seed entered, the fraction comes from mulberry32, a small seeded pseudorandom generator written in 2017 by Tommy Ettinger. Mulberry32 keeps a single 32-bit number as its state, adds the constant 0x6D2B79F5 on every call, mixes the result through a few multiplications and bit shifts, and divides by 4,294,967,296, which is 2 to the power of 32, to produce a fraction between 0 and 1. The same seed always produces the same sequence, which is why seed 42 always gives 61 on a 1 to 100 draw: the first fraction from seed 42 is 0.6011037519201636, and 1 plus the whole-number part of 0.6011037519201636 times 100 is 61.
The worked examples below use real draws from this tool, so you can check them yourself by entering the same seed and the same settings:
- Single, seed 42, 1 to 100: 61. The first fraction is 0.6011037519201636, so the whole-number part of 0.6011037519201636 times 100 is 60, and 1 plus 60 is 61.
- List, seed 5, 1 to 10, 8 numbers, repeats allowed: 7, 8, 3, 7, 1, 6, 8, 5. Note the repeats: 7 and 8 each appear twice. That is normal, not a defect, and the section on repeats below explains why.
- List, seed 5, 1 to 10, 8 numbers, no repeats: 7, 8, 3, 1, 6, 5, 10, 4. The same seed and the same range, but repeats are skipped and drawing continues until 8 different numbers are collected.
- Dice, seed 2, two d6: 5 and 2, for a total of 7. The most common total on two dice, and the first draw from this seed lands on it.
- Coin, seed 6, 10 flips: tails, heads, tails, heads, tails, heads, heads, tails, tails, heads. Five heads and five tails, in a mixed order.
- Negative range, seed 123, -10 to 10: 6. The formula works the same way below zero: the range size is 21, and the draw is -10 plus the whole-number part of the fraction times 21.
- Large range, seed 99, 1 to 1,000,000: 260,466. Large ranges work the same way as small ones; the fraction is simply scaled further.
For no-repeat lists, the tool draws one number at a time and keeps only numbers it has not drawn yet, drawing again whenever a repeat turns up. This is called rejection sampling, and it keeps every possible set of numbers equally likely: each new draw is uniform over the numbers still available. For dice, each die is a separate draw from 1 to the number of sides. For coins, each flip is a separate draw where a fraction below 0.5 is heads and 0.5 or above is tails, which gives each side exactly half the fraction range.
Pseudorandom vs true random
The numbers on this page are pseudorandom, not truly random, and the difference matters. A pseudorandom number generator, or PRNG, is an algorithm: it starts from a seed value and applies fixed arithmetic to produce a sequence of numbers that look random. Given the same seed, it produces the same sequence every time. That determinism is a feature here, because it is what makes the seed box work, and it is what lets anyone replay and check a draw. A true random number generator, or TRNG, draws its unpredictability from a physical process instead: atmospheric noise, radioactive decay, or thermal noise in a circuit. RANDOM.ORG, the best-known true random service, samples atmospheric noise with a radio. A TRNG sequence cannot be replayed, because the physical process never repeats itself exactly.
RANDOM.ORG sums up the trade-off in a short comparison. PRNGs are efficient, deterministic, and periodic: they produce many numbers quickly, the same seed replays the same sequence, and the sequence eventually repeats. TRNGs are inefficient, nondeterministic, and aperiodic: they are slow, no sequence can be replayed, and there is no period. Mulberry32, the seeded generator on this page, has a period of exactly 2 to the power of 32, about 4.3 billion numbers, because its 32-bit state steps through every 32-bit value before cycling. That is far more numbers than any visitor will ever draw here, so the period is not a practical limit, but it is a real one: a PRNG with a 32-bit state can only ever produce 4.3 billion different sequences of outputs, one per starting state.
For everyday uses, pseudorandom numbers are the right tool. Picking a raffle winner, choosing a random student, rolling dice for a game, shuffling a practice quiz, or deciding who goes first are all jobs where a good PRNG is indistinguishable from a physical draw. The numbers look random, they pass statistical tests for randomness, and no pattern in them is useful to anyone watching. Mulberry32 passes gjrand's 13 statistical tests with no failures, which is the kind of check that catches a bad generator. Where pseudorandom numbers are the wrong tool is anywhere the unpredictability itself is the point: encryption keys, passwords, security tokens, gambling, and lotteries. There, an attacker who learns the seed, or the algorithm and enough outputs, can predict what comes next. RANDOM.ORG puts it plainly: PRNGs are not suitable for applications where it is important that the numbers are really unpredictable, such as data encryption and gambling. This page says the same thing in its disclaimer and in the limits section below, because honest labeling is part of the tool.
Is every number equally likely?
Yes, within the limits of floating-point arithmetic. The fraction the generator produces is approximately uniform between 0 and 1, which means it is as likely to land in any equal-width slice of that range as in any other. The draw formula divides the range from 0 to 1 into as many equal slices as there are numbers in your range, and each number owns one slice. For 1 to 100, the number 61 owns the slice from 0.60 up to, but not including, 0.61. Every number owns a slice of the same width, 1 divided by 100, so every number has the same chance: 1 in 100. MDN describes Math.random as having approximately uniform distribution over its range, and the seeded mulberry32 path is built to the same standard.
Two details keep this honest. First, the tool never uses a remainder, the modulo operator, to fit a random value into a range. Taking a random integer modulo the range size is a common shortcut, and it biases the result whenever the range size does not divide the generator's output range evenly: the low numbers get one extra chance each. Scaling a uniform fraction and taking the floor has no such bias, because the slices are exactly equal. Second, the tool never rounds the scaled fraction, for the reason given above: rounding gives the end numbers half slices. Floor, not round, not modulo.
Uniform also means independent: each draw starts fresh from the next fraction in the sequence, and no draw remembers the one before it. Drawing 61 does not make 61 less likely next time, and rolling three sixes in a row does not make a fourth six less likely. The only exception is the no-repeat list mode, where drawn numbers are deliberately removed from the pool, so the odds change by design: after drawing 7 from 1 to 10, the next no-repeat draw has 9 numbers left, each with a 1 in 9 chance.
One more honest note: no browser generator is perfectly uniform. JavaScript numbers are 64-bit floating-point values, so the fraction can only take a finite set of values, and the slices at the edges are microscopically uneven. MDN notes that the ranges claimed for the scaling formulas are not exact in floating point. For ranges up to a billion, the unevenness is far below anything a user could ever detect: the difference in probability between the luckiest and unluckiest number in a 1 to 100 draw is roughly 1 part in 10 to the power of 13. It matters for cryptographers. It does not matter for raffles.
Dice odds: what two dice really total
A fair die gives every face the same chance: a d6 lands on each number from 1 to 6 with probability 1 in 6, about 16.67 percent. That is true of every die this tool offers, from the d4 to the d20. A d20 rolls a natural 20, the top face, once in 20 rolls on average, 5 percent of the time, and a natural 1 just as often. The shape of the die does not change the fairness: a die is fair when its faces are symmetric, and the standard polyhedral dice used in tabletop games, the d4, d6, d8, d10, d12, and d20, are all built that way. Twenty-sided dice are old: examples survive from Ptolemaic Egypt in the 2nd century BCE, and from the Roman world in the 2nd century CE. Opposite faces of a standard d6 add to 7, a convention that goes back thousands of years.
One die is uniform, but two dice are not, and that surprises people. Two six-sided dice have 36 equally likely pairs, 6 faces on the first die times 6 on the second, but the totals are not equally likely, because some totals can be made more ways than others. Only one pair makes 2, a 1 and a 1, and only one pair makes 12, a 6 and a 6. Six pairs make 7: 1 and 6, 2 and 5, 3 and 4, 4 and 3, 5 and 2, 6 and 1. So 7 comes up 6 times in 36 rolls, about 1 roll in 6, while 2 and 12 each come up once in 36 rolls. The full table:
| Total on 2d6 | Pairs that make it | Chance |
|---|---|---|
| 2 | 1 (1, 1) | 1 in 36, about 2.78 percent |
| 3 | 2 (1, 2 and 2, 1) | 2 in 36, about 5.56 percent |
| 4 | 3 | 3 in 36, about 8.33 percent |
| 5 | 4 | 4 in 36, about 11.11 percent |
| 6 | 5 | 5 in 36, about 13.89 percent |
| 7 | 6 | 6 in 36, about 16.67 percent |
| 8 | 5 | 5 in 36, about 13.89 percent |
| 9 | 4 | 4 in 36, about 11.11 percent |
| 10 | 3 | 3 in 36, about 8.33 percent |
| 11 | 2 (5, 6 and 6, 5) | 2 in 36, about 5.56 percent |
| 12 | 1 (6, 6) | 1 in 36, about 2.78 percent |
The pattern is a triangle, peaking at 7, and it is why board games built on two dice put the most common events on 7. The average total of two dice is 7, because the average roll of one d6 is 3.5, the midpoint of 1 and 6, and two of them average 3.5 plus 3.5. The same rule scales: ten d6 average 35, the midpoint of their range from 10 to 60, and with more dice the totals cluster ever more tightly around the average. Rolling ten dice and totaling 10, all ones, has probability 1 in 60,466,176, which is 6 to the power of 10: possible, but do not hold your breath.
Coin flips and streaks
A coin flip is the simplest random draw there is: two outcomes, each with probability 1 in 2. This tool flips by drawing a fraction and calling it heads below 0.5 and tails at 0.5 or above, which splits the fraction range exactly in half. Every flip is independent, which means the coin has no memory. Five heads in a row does not make tails more likely next time: the next flip is still 50-50. The belief that a run of one outcome makes the other outcome due is the gambler's fallacy, and it is the most common mistake people make with random sequences.
Streaks feel wrong, but they are normal. Ten flips produce 1,024 possible sequences, 2 to the power of 10, and all ten heads is one of them, so it happens about 1 time in 1,024 sets of ten flips, roughly 0.1 percent. That sounds rare, and it is, for a specific set of ten flips. But a long session contains many overlapping sets of ten, and across them a run of ten heads becomes likely rather than remarkable. In 100 flips, the chance of seeing a run of at least 6 heads somewhere in the sequence is well over 50 percent. When your ten flips come back with four heads in a row in the middle, the coin is behaving exactly as a fair coin should.
Short runs also mislead in the other direction. Ten flips landing 8 heads and 2 tails feels lopsided, but it is not unusual: the chance of 8 or more heads in ten flips is about 5.5 percent, roughly 1 time in 18. And the most likely single split, 5 heads and 5 tails, happens only about 24.6 percent of the time, 252 of the 1,024 sequences. Most sets of ten flips are not 5-5. Fairness is a long-run property: over thousands of flips the heads share settles near 50 percent, but any short run can wander far from even. If you want to see that for yourself, flip ten coins here twenty times and watch the counts: the average across all twenty sets will sit near 5 heads, while the individual sets scatter from 2 to 8.
Why lists repeat numbers
Draw 5 numbers from 1 to 10 with repeats allowed, and you will see a duplicate most of the time: the chance of at least one repeat is about 70 percent. That surprises people who expect 5 draws from 10 numbers to spread out neatly. The reason is the same one behind the famous birthday problem: what matters is not how many numbers you draw, but how many pairs of draws you make. Five draws make 10 pairs, and each pair has a 1 in 10 chance of matching. With 10 pairs each getting a shot, a match somewhere is the likely outcome, not the exception.
The birthday problem is the classic version. In a room of 23 people, the chance that at least two share a birthday is 50.7 percent, even though there are 365 days in the year. With 50 people it is 97.0 percent, and with 70 people it is 99.9 percent. Twenty-three people make 253 pairs, and 253 pairs each with a 1 in 365 chance of matching add up fast. The general rule is that the chance of a repeat grows with the square of the number of draws divided by twice the size of the pool, approximately 1 minus e to the power of negative n times n minus 1 over 2d, where n is the number of draws and d is the size of the pool. For 5 draws from 10 numbers, that approximation gives about 63 percent, close to the exact 69.8 percent. The exact figure comes from counting directly: the chance of no repeat is 10 times 9 times 8 times 7 times 6, divided by 10 to the power of 5, which is 0.3024, so the chance of at least one repeat is 1 minus 0.3024, or 69.76 percent.
This is why the tool offers a no-repeat option, and why it matters which one you pick. Repeats allowed is the right choice when each draw is genuinely independent: lottery-style quick picks, dice-style draws, or sampling where the same item can be picked twice. No repeats is the right choice when each number can only be used once: raffle tickets, shuffled questions, assigned slots, or a random ordering of a fixed list. The two modes answer different questions, and mixing them up is the most common list mistake. If you draw 5 numbers from 1 to 10 with repeats allowed and get 7 twice, the tool is not broken. If you need 5 different numbers, turn on No repeats and draw again.
What this tool is not for
This tool is built for everyday random draws, and it says so plainly. It is not suitable for cryptography, gambling, lotteries, passwords, or anything where money or security depends on the numbers being unpredictable. The reasons are specific, not vague caution.
- Cryptography and passwords. Both generators on this page are predictable to anyone who knows the method. Math.random cannot be seeded by the user, but its output can be predicted from a short run of observed values, and MDN states plainly that it does not provide cryptographically secure random numbers and should not be used for anything related to security. The seeded path is deterministic by design: anyone with the seed can reproduce the whole sequence. For keys, tokens, and passwords, use the Web Crypto API, specifically Crypto.getRandomValues, which draws from the operating system's secure entropy source, or a password manager's generator.
- Gambling and lotteries. Games of chance need numbers that no player can predict or influence, and regulators require certified systems for exactly that reason. A browser tool whose algorithm is published on the page cannot meet that bar. RANDOM.ORG's guidance puts lotteries, draws, games, and gambling in the true-random column, not the pseudorandom column. If you are running a draw where money changes hands, use a service built and audited for that purpose, with public records of the draw.
- Scientific sampling where auditability matters. Random sampling for research, drug trials, or public-sector draws needs a documented, auditable source of randomness, and often a true random source. A seeded generator is actually useful in simulation work, where replaying the same sequence is a feature, but the choice of generator and seed should be recorded in the study method, and a 32-bit generator is too small for large simulations: its period of 4.3 billion values can be exhausted by a big Monte Carlo run.
- Anything where a repeat would be a security flaw. Because mulberry32 has only 2 to the power of 32 possible states, two different seeds can produce overlapping sequences, and the same seed always produces the same sequence. That is fine for a classroom raffle and fatal for a session token.
None of this makes the tool less useful for its real jobs. It makes the boundary clear, which is the point: a random number generator that pretends to be suitable for everything is one you cannot trust for anything.
Common uses
The most common use is the raffle: number the entries from 1 to however many there are, draw one number, and that entry wins. For a prize draw with several winners, use the list mode with No repeats, so nobody wins twice. For a classroom, number the students and draw to pick who answers, who presents first, or which group goes first: it is visibly fair, and the students can watch the draw happen. If your list of names lives in a document, the Word Counter can tell you how many entries it has before you set the range.
Games are the second home of this tool. Board game nights use the dice roller when the physical dice are missing or when a game needs dice nobody owns, like a d20 for a tabletop session or three d8 for a damage roll. The coin flip settles who goes first, who picks the movie, or which of two options to take when you genuinely cannot decide. Puzzle and quiz makers use lists to shuffle question order or to pick a random subset of questions for a practice round.
Less obvious uses include sampling and testing. A researcher doing a quick pilot can draw random page numbers, random rows from a numbered list, or random times of day to observe. A developer testing an app can generate random test inputs, and the seed box makes those tests repeatable: the same seed produces the same inputs on every run, so a bug found with one seed can be reproduced exactly. A writer or artist can use random numbers to break a block: pick a random prompt number, a random chapter to revise, or a random color from a numbered palette.
Whatever the use, the same advice applies: decide the range before you draw, write the range down if anyone else is involved, and use the seed box when the draw needs to be checkable later. A draw nobody can verify is only as trustworthy as the person who ran it. This generator is one of the free tools on the Tools Elite homepage, where you can search the full collection by name or category.
Common mistakes to avoid
- Forgetting the ends count. A range of 1 to 100 includes 100. If you want numbers from 1 to 99, set the maximum to 99. The most common off-by-one error in random draws is setting a range one wider than intended.
- Reading patterns into short runs. Three sixes in a row, four heads in a row, or the same number twice in a list are all normal. Random sequences are lumpy. Only long runs reveal fairness, and a short run that looks too even, alternating heads and tails like clockwork, is more suspicious than a streak.
- Using repeats allowed when you need unique numbers. Drawing 5 raffle winners with repeats allowed can give the same ticket twice. If each number can only win once, turn on No repeats before you draw.
- Asking for more unique numbers than the range holds. Ten unique numbers from 1 to 5 cannot exist. Widen the range or lower the count. The tool refuses the draw rather than returning a short list.
- Expecting a seed to make a draw more random. A seed does the opposite: it makes the draw repeatable. Seeds are for replaying and checking, not for improving randomness. A blank seed gives a fresh draw every time.
- Using this tool for passwords, gambling, or lotteries. See the limits section above. The generator is pseudorandom, its algorithm is public, and seeded draws are reproducible by anyone with the seed.
- Rounding or trimming a draw to fit a smaller range. If you need a number from 1 to 6, set the range to 1 to 6. Drawing from 1 to 100 and taking the remainder, or dropping digits, can bias the result. Set the range you actually want and let the tool do the scaling.
Frequently asked questions
Is this random number generator truly random?
No, it is pseudorandom, and the page says so honestly. With no seed, draws come from the browser's Math.random, a pseudorandom generator. With a seed, draws come from mulberry32, a small seeded generator whose sequence is fixed by the seed. Both produce numbers that look and test as random for everyday uses, but both are deterministic algorithms, not physical randomness. True randomness comes from physical processes like atmospheric noise, which is what RANDOM.ORG samples. For raffles, games, classrooms, and decisions, pseudorandom is the right tool. For cryptography, gambling, and lotteries, it is not, and this page says so in its limits section.
Is every number equally likely?
Yes. The tool scales a uniform fraction between 0 and 1 into your range by taking the whole-number part of the fraction times the range size, then adding the minimum. Each number owns an equal slice of the fraction range, exactly 1 divided by the range size wide, so each number has the same chance: 1 in 100 for a range of 1 to 100. The tool never uses a remainder or rounding to fit the range, because both of those shortcuts bias the result. The only unevenness is at the level of floating-point arithmetic, about 1 part in 10 to the power of 13, far below anything a user could detect.
What does the seed do?
The seed makes a draw repeatable. Leave it blank and every draw is fresh. Enter a whole number and the tool uses the mulberry32 generator with that seed, so the same seed and the same settings always give the same result: seed 42 on a 1 to 100 single draw always returns 61. Seeds are useful for replaying a draw, sharing a draw so someone else can check it, and making repeatable test data. A seed does not make a draw more random. It makes it deterministic, which is the opposite, and it is a feature, not a flaw, for those uses.
Why did my list repeat a number?
Because repeats are normal when repeats are allowed. Drawing 5 numbers from 1 to 10 repeats a number about 70 percent of the time, for the same reason 23 people in a room share a birthday more often than not: five draws make ten pairs, and each pair has a 1 in 10 chance of matching. The exact chance of at least one repeat in 5 draws from 1 to 10 is 69.76 percent. If you need every number different, turn on No repeats before you draw. The tool then skips duplicates and keeps drawing until it has the count you asked for, and it refuses the draw if the count is larger than the range.
What are the odds of rolling a 7 with two dice?
Six in 36, about 16.67 percent, or about 1 roll in 6. Two six-sided dice have 36 equally likely pairs, and six of those pairs add to 7: 1 and 6, 2 and 5, 3 and 4, 4 and 3, 5 and 2, and 6 and 1. Seven is the most likely total on two dice. The least likely totals are 2 and 12, each with only one pair, 1 in 36, about 2.78 percent. A single die is uniform, with each face at 1 in 6, but totals of two dice form a triangle peaking at 7, because some totals can be made more ways than others.
Can I use this tool for a lottery or a raffle with money prizes?
For a casual raffle among friends, a classroom, or a club, yes: number the entries, draw with No repeats if there are several winners, and use the seed box if anyone wants to check the draw later. For a lottery or any draw where money changes hands and the result could be disputed, use a service built and audited for that purpose, with public records of the draw. This tool is a browser page running a published pseudorandom algorithm, and seeded draws are reproducible by anyone with the seed. RANDOM.ORG's guidance puts lotteries and draws in the true-random column, and regulated draws need certified systems.
How do I pick a random winner from a list of names?
Number the names from 1 to however many there are, then draw one number in that range with the single number mode. The name with the drawn number wins. For several winners, use the list mode with No repeats turned on, so no name wins twice. If the list is long, count the entries first so the range is right. If anyone might question the draw, enter a seed before drawing and note it down: the same seed and range always reproduce the same winner, so anyone can verify the result. The history strip keeps your last 10 draws on the page, and the Copy results button copies the draw as plain text.
Sources
Every figure on this page comes from one of the sources below, each accessed 20 November 2026, or from arithmetic shown in full on the page. The worked examples are real draws from this tool and can be checked by entering the same seed and settings.
- developer.mozilla.org — Math.random() reference: returns a floating-point pseudorandom number from 0 up to but not including 1, with approximately uniform distribution; the implementation selects the initial seed and it cannot be chosen or reset by the user; does not provide cryptographically secure random numbers, and the Web Crypto API, specifically Crypto.getRandomValues, should be used instead for security purposes; the inclusive integer formula is the floor of Math.random times the maximum minus the minimum plus 1, plus the minimum; using Math.round instead gives a non-uniform distribution. Accessed 20 November 2026.
- random.org — Introduction to Randomness and Random Numbers, by Dr Mads Haahr: RANDOM.ORG generates randomness via atmospheric noise; a random number is drawn from a set of possible values, each equally probable, a uniform distribution; PRNGs are efficient, deterministic, and periodic, and are not suitable for applications where it is important that the numbers are really unpredictable, such as data encryption and gambling; TRNGs extract randomness from physical phenomena, are inefficient, nondeterministic, and aperiodic; lotteries and draws, games and gambling, random sampling, and security are best served by TRNGs, while simulation and modeling are best served by PRNGs. Accessed 20 November 2026.
- gist.github.com — Mulberry32 PRNG, written in 2017 by Tommy Ettinger: a 32-bit variant of the Thrust PRNG, dedicated to the public domain; the period is 2 to the power of 32 exactly, since the state steps through each 32-bit unsigned integer before cycling; the constant is 0x6D2B79F5; it passes gjrand's 13 tests with no failures and a total P-value of 0.984 on 4 GB of generated data. Accessed 20 November 2026.
- 4rknova.com — Mulberry32: A Tiny, Fast, Deterministic RNG: a 32-bit deterministic pseudorandom generator where the same seed always gives the same sequence; the state is a single 32-bit number updated on each call and mixed through bitwise operations and integer multiplication, then divided by 4,294,967,296 to give a float in the range 0 up to but not including 1; not cryptographically secure, and not intended to be. Accessed 20 November 2026.
- en.wikipedia.org — Birthday problem: in a group of 23 randomly chosen people, the probability that at least two share a birthday exceeds 50 percent, at 50.7 percent; with 50 people it is 97.0 percent and with 70 people it is 99.9 percent; the general approximation for n draws from d values is 1 minus e to the power of negative n times n minus 1 over 2d. Accessed 20 November 2026.
- en.wikipedia.org — Dice: a traditional die is a cube with faces from 1 to 6, each value equally likely when thrown; opposite sides of a modern die traditionally add up to seven; twenty-sided dice date back to the 2nd century CE, and from Ptolemaic Egypt as early as the 2nd century BCE. Accessed 20 November 2026.