Random Number Generator
Generate random numbers within any range. Support for multiple numbers, unique values, and sorting.
Generator tools and private list pickerResult
Fill in the fields above, then press Generate.
Generate bounded random integers from a deduplicated union of inclusive ranges. Use negative and zero bounds, parity controls, replacement and numeric sorting.
Examples
Overlapping ranges
Ranges 1–3 and 3–5 form five eligible values: 1, 2, 3, 4, 5. The shared endpoint 3 has the same chance as every other eligible value.
Parity quota
For 1–10, count 4 and exact odd count 2, each output has two odd and two even integers. Without replacement, all four values are distinct.
Random labels are not balanced teams
Thirty independent labels from 1–5 do not guarantee six students per team. This tool samples labels, not balanced groups.
Frequently Asked Questions
What are the limits?
Bounds must be safe integers, with at most 11 total ranges and 1,000 outputs. The eligible population must not exceed Number.MAX_SAFE_INTEGER. Fractions, empty bounds, reversed ranges and impossible unique/parity counts fail before sampling.
Is every eligible value equally likely?
Without an exact quota, each eligible value has equal probability per draw; unique draws are uniform ordered samples without replacement. A quota instead samples uniformly among ordered outputs satisfying that quota, so unconditional odds differ by parity.
How are summary statistics derived?
Sum, mean fraction and median fraction use exact integer arithmetic internally. Displayed generated values remain safe integers. Fractions are retained when an average is not an integer.
Related Calculators
Quick Tips
- •Use Add range for disjoint intervals.
- •Leave exact odd count empty for ordinary uniform draws.
- •A small draw from a large domain uses bounded memory.