Syntax
- float/string sum(array)
Parameters
- array—(float[], string[], bool[])
Returns
The sum functions returns
- the sum of all elements in a float array
sum( [1,2,3] ) 6
- or the count of all true elements in a bool array
sum( [true,false,true] ) 2
- or the concatenation of all elements in a string array
sum( ["a","b","c"] ) "abc"
Related
Examples
frontLength = sum( comp(fe) { street.front : scope.sx } )
numberSmallFaces = sum( comp(f) { all : geometry.area < 0.1 } )