Modul:Sraz
Vzhled
local p = {}
function p.pred(f)
e = tonumber(f.args[1])
r = 0
for k, v in pairs(f.args) do
k, v = tonumber(k), tonumber(v)
if k ~= 1 and v ~= 0 then
if k > r and k < e then
r = k
end
end
end
return r
end
function p.po(f)
e = tonumber(f.args[1])
r = 99999999999999
for k, v in pairs(f.args) do
k, v = tonumber(k), tonumber(v)
if k ~= 1 and v ~= 0 then
if k < r and k > e then
r = k
end
end
end
return r
end
return p