**Tom’s Tutorials For Excel: Using the RAND Function to Extract Random Data**

Here are examples of how numbers or data can be extracted using the `RAND`

function.

The examples and formulas listed below relate to the following picture.

Example 1: Randomly return a number between numbers, such as from 1 to 10.

Formula in cell A4 is `=INT(RAND()*10)+1`

Example 2: Example 1 in practice, to randomly return an item in a 10-item list.

Formula in cell E7 is `=INDEX(A8:A17,INT(RAND()*(10)+1))`

Example 3: Similar to Example 1, this time from 65 to 90.

Formula in cell A20 is `=INT(RAND()*(91-65)+65)`

Example 4: Example 3 in practice, to randomly return a letter of the alphabet.

Formula in cell A23 is `=CHAR(INT(RAND()*(91-65)+65))`

Example 5: Random time between two times such as from 9:00 AM and 2:00 PM.

Formula in cell A26 is `=RAND()*(TIME(9,0,0)-TIME(14,0,0))+TIME(14,0,0)`

## Leave a Reply