I've the following but it doesn't work:
<%= (5..30).sample %>
Select the cell in which you want to get the random numbers. In the active cell, enter =RANDBETWEEN(1,100). Hold the Control key and Press Enter.
Give this a shot.
<%= [*5..30].sample %>
...or...
<%= rand(5..30) %>
This would generate a random number in that range:
5 + rand(25)
Simply add the min to the rand(max-min).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With