July 2018
Beginner
202 pages
5h 42m
English
Lua provides a pseudo-random number generator. This means a program will generate the same random number on every run, unless the random number is seeded. The random function can be called with the following arguments:
When generating a random number, min and max must be integer values. If the numbers provided are not integers, Lua will cast the numbers to be integers by discarding the decimal part.
To get a random sequence of numbers each time an application is run, the random number generator must be seeded. Seeding the random ...