Last Updated on November 12, 2022 by Humera hallari
To create a random number in Microsoft Excel is actually very easy. We just need to use the formula =rand(), but the result is a decimal number value so we need to convert it to a real number.
To convert the result of formula =rand() in excel, we simply use the formula =rank. EQ() so that the result of decimal number =rand() will be converted to real number. Here’s a simple formula.
How to Generate Random Numbers in Excel
We assume using cell E2-E22 to generate random number, and we will use F2-F22 to convert from decimal number result from random number of decimal number to real number.
1) Select the cell from E2-E22, then press the Ctrl key and click to the cell E2, then type the formula =rand(), press the Ctrl key and then Enter.
2) Use this formula in cell F2 =RANK. EQ(E2,$E$2:$E$22) and drag down to F22.
That’s how to generate random numbers in excel. You can download the project and its source code through the link below.