Introduction to Lua Programming-Final Project

0

function sumAllNumbers(num)
local result = 0
for i=1, num, 1 do
result = result + i
end
return result

end

print("The final sum is: ".. sumAllNumbers(12))