Const
The SeededRandom class for creating reproducible random sequences
Generate a random number in a specified range
Lower bound
Upper bound
Optional
step: numberOptional step size
Optional custom random function
Random number in specified range
Generate a random integer in a specified range
Lower bound (inclusive)
Upper bound (inclusive)
Optional
step: numberOptional step size
Optional custom random function
Random integer in specified range
Generate a random BigInt in a specified range
Lower bound (inclusive)
Upper bound (inclusive)
Optional
step: bigintOptional step size
Optional custom random function
Random BigInt in specified range
Fill a buffer with random bytes
Buffer to fill (ArrayBuffer or TypedArray)
Optional
start: numberStart position (optional)
Optional
end: numberEnd position (optional)
Optional custom random function
The filled buffer
Choose multiple random elements from an array without replacement
Array to choose from
Number of elements to choose
Optional custom random function
Array of randomly chosen elements
Generate a random string of specified length
Length of the string to generate
Character set to use (default: alphanumeric)
Optional custom random function
Random string
Generate a weighted random choice
Array of items to choose from
Array of weights corresponding to items
Optional custom random function
Randomly chosen item based on weights
Generate a random number from normal distribution (Box-Muller transform)
Mean of the distribution (default: 0)
Standard deviation (default: 1)
Optional custom random function
Random number from normal distribution
Collection of random utility functions