Module:Sandbox/Hike395/AndOr explained

local p = local getArgs = require("Module:Arguments").getArgs

function p._main(args) for i = 1, args.max, 2 do if args[i] and args[i+1] then return args[i+1] end end return nilend

function p.main(frame) local origArgs = getArgs(frame) local args = local max = 0 for k, v in pairs(origArgs) do if tonumber(k) then args[k] = v if k > max then max = k end end end args.max = max return p._main(args) or ""end

return p