Method 1 – Use the Excel RAND Function to generate Random Numbers Between 0 and 1
The RAND function returns a random number greater than or equal to 0 or less than 1, evenly distributed. The random numbers change on each recalculation.
Steps
- Go to B4. (here)
- Enter the following formula.
=RAND()
- Press Enter and drag down the Fill Handle icon.
Method 2 – Generate Random Numbers Using the RANDARRAY Function
The RANDARRAY function returns an array of random numbers.
Steps
- Go to B4. (here)
- Enter the following formula.
=RANDARRAY( , ,0, 1,FALSE)
Note:
The first two arguments define the rows and columns to form an array. You can skip or specify the row and column number. The 3rd and 4th arguments indicate the minimum and maximum values of the range. Here, 0 and 1. The last argument has two options: integers and decimals. FALSE is chosen for decimal numbers ( It’s FALSE by default).
- Press Enter and drag down the Fill Handle icon.
Create Random Integers Between Two Numbers in Excel
The ROUND function rounds a number to a specified number of digits.
Steps
- Go to B4. (here)
- Enter the following formula.
=ROUND(RAND()*(5-2)+2,0)
- Press Enter and drag down the Fill Handle icon.
Random Occurrence of Pre-specified Numbers Between 0 & 1
The CHOOSE function chooses a value or action to perform from a list of values based on an index number.
The RANDBETWEEN function returns a random number between the specified numbers.
Steps
- Go to B4. (here)
- Enter the following formula.
=CHOOSE(RANDBETWEEN(1,4),0.3,0.1,0.8,0.5)
- Press Enter and drag down the Fill Handle icon.
Download Practice Workbook
Download the practice workbook.
<< Go Back to Random Number in Excel | Randomize in Excel | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!