summaryrefslogtreecommitdiffstats
path: root/docs/content/en/functions/math/Sum.md
blob: e14bc924b1b9c2d025e6ab8f7f229c52c0ad5df0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
---
title: math.Sum
description: Returns the sum of all numbers. Accepts scalars, slices, or both.
categories: []
params:
  functions_and_methods:
    aliases: []
    returnType: float64
    signatures: [math.Sum VALUE...]
---

```go-html-template
{{ math.Sum 1 (slice 2 3) 4 }} → 10
```