Open steve-lorenz opened 6 years ago
// Generate a pseudo-random number from 1 to 100.
// rand() % 100 will result in a number 0 to 100
// add 1 to shift the range to get a possible range 1 to 100.
side = 1 + rand() % 100;
@theresasvrcina This is great! Depends what we use, python has a random
module
import random random.randint(1, 100)
Would work in python.
right right depends what language we use.
A random number generator to generate integers between 1 - 100. To simulate the D100.