Can Roll dice not starting from 1?

Hello there ! :waving_hand:

I need to generate random numbers starting from 20 to 200.

Is there a way to do this with the roll dice ? :folded_hands:

Hi @Korbib :slight_smile:

You could probably do this easily in two steps:

  1. Create a Roll Dice column with the value 180 in Sides

  2. Add a Math column to add 20 to this result


There is also another option, with a Random Number column (and a Math one after that again). The formula to apply is - in your case - the following: CEILING(random*180) + 20


Last important point: in both cases (Rool Dice & Random Number), you have the Seed argument to define.
If you use a fixed value, such as the Row ID, the result will always be the same for this specific row.
If you want the random value to be different, a common way to make it works is to use the Current time value or something that can change over time, when the user hits a button for instance.

4 Likes

Ho yes ! :partying_face:

That’s exactly what I wanted :ok_hand:

Merci m’sieur :folded_hands:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.