math.random()// generate a random number between 0 and 1math.random(max)// generate a random number between 0 and maxmath.random(min,max)// generate a random number between min and maxmath.random(size)// generate a matrix with random numbers between 0 and 1math.random(size,max)// generate a matrix with random numbers between 0 and maxmath.random(size,min,max)// generate a matrix with random numbers between min and max

math.random();// returns a random number between 0 and 1math.random(100);// returns a random number between 0 and 100math.random(30,40);// returns a random number between 30 and 40math.random([2,3]);// returns a 2x3 matrix with random numbers between 0 and 1