sum

Definition: atom a = sum(object x)
Description: Add together all elements of x, however deeply nested.
Comments: This function may be applied to an atom or all elements of a sequence.

Note: Unlike several other functions there is no separate sq_sum function, instead the one routine (see builtins\psum.e) can be used for any argument.
Example:
r = sum({1,2,3,4})
-- r is 10