30 lines
445 B
Lua
30 lines
445 B
Lua
global b = 5
|
|
|
|
function add(x)
|
|
return function (y)
|
|
x = x + 1
|
|
b = b + 1
|
|
return x + y, 1, 2, b
|
|
end
|
|
end
|
|
|
|
function min(x, y)
|
|
local m = x
|
|
if y < x then
|
|
m = y
|
|
end
|
|
return m
|
|
end
|
|
|
|
global sometable = {}
|
|
sometable["hello"] = {}
|
|
sometable["hello"].there = "my dude"
|
|
|
|
print(max(11, 9))
|
|
print(add(10)(15))
|
|
print(add(10)(15))
|
|
print(b)
|
|
print(min(11, 9))
|
|
print(10 - 15)
|
|
print("hello there!")
|
|
print(nil or 0) |