Content deleted Content added
add function to get random dates; and add support for random numbers over 2^32-1 (using an algorithm supplied by User:Anomie) |
attempt at getting better randomness |
||
Line 5:
local makeList = require('Module:List').makeList
-- Set the seed for the random number
-- edit rate, but should also work well on smaller wikis due to the variability of os.time() (the current time)
-- and os.clock() (the time the program takes to run).
math.randomseed(mw.site.stats.edits + mw.site.stats.pages + os.time() + math.floor(os.clock() * 1000000000))
-- Call math.random a few times to avoid getting the same first answer every time.
math.random()
math.random()
math.random()
--------------------------------------------------------------------------------------
|