Log In  

Cart #tuple_sum-0 | 2022-07-26 | Code ▽ | Embed ▽ | No License
3

Feature Overview

SUM() returns the sum of the numbers in the given arguments.

  • If the argument contains nil or false, the result will not be correct.
  • If too many arguments are given, Out of memory is returned. (In the sample, up to 710 arguments)
  • This function consumes 15 Token.

If you are concerned about some of the problems, consider using the "More Argments Ver" code.

--more argments ver(17 token)
function sum(a,...)
 foreach({...},function(v)
  a+=v
 end)
 return a
end

Other tuple trick code: INRNG()

P#63121 2022-07-26 09:26


[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2024-03-29 10:44:03 | 0.009s | Q:14