This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
today = os.date("t*") --, "%Y-%m-%d") | |
print(today) | |
time = os.time(today) | |
print(time) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function hello_lua() | |
print "Hello Lua!\n" | |
local a = {1,2} | |
local i = a[0] or 10 | |
print(i) | |
end | |
hello_lua() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function hello_lua() | |
local a, _, _, d = string.match("111_222_333_8", "(%d*)_(%d*)_(%d*)_?(%d*)") | |
print (a, d) | |
local na, nb, nc, nd = string.match("111_222_333_6", "(%d*)_(%d*)_(%d*)_?(%d*)") | |
local id, ind = tonumber(d), tonumber(nd) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local function Print(...) | |
if ... == nil then return end | |
local Output = tostring(...) | |
return print(Output)--ezzz Useless tuff haha rekt ezz | |
end | |
Print("UrMomGay") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local function Print(...) | |
if ... == nil then return end | |
local Output = tostring(...) | |
return Output | |
end | |
Print(2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function hello_lua() | |
print "Hello Lua!" | |
end | |
hello_lua() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function eval(a,b,c,x) | |
return a + (b + c * x) * x | |
end | |
function regression(xa,ya) | |
local n = #xa | |
local xm = 0.0 | |
local ym = 0.0 | |
local x2m = 0.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Variable definition: | |
local dis, b | |
-- Initialization | |
dis = 10 | |
b = 0 | |
print(dis, b) | |
for b = 0, dis do | |
print(curr) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- variables | |
first = { | |
{value = 1}, | |
{value = 2}, | |
{value = 3} | |
} | |
second = { | |
{value = 1}, | |
{value = 2}, | |
{value = 3} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function hello_lua() | |
print "Hello Lua!" | |
end | |
hello_lua() |