Make the math challenge a smidgen more challenging and varied..
This commit is contained in:
parent
5d4e325dd1
commit
9997ada0ef
1 changed files with 2 additions and 2 deletions
|
|
@ -8,8 +8,8 @@ local sock = assert(ngx.req.socket(true))
|
|||
-- (otherwise we'd be asking the same question every time we restart nginx).
|
||||
math.randomseed(os.time())
|
||||
-- Generate the actual math quiz..
|
||||
local num1 = math.random(2,5)
|
||||
local num2 = math.random(2,4)
|
||||
local num1 = math.random(1,8)
|
||||
local num2 = math.random(1,9-num1)
|
||||
-- ...we should probably know the answer, too..
|
||||
local ans = num1+num2
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue