# List sum, average, max, min in Jira Automation: examples

URL: https://goingstellar.ro/reference/smart-values/list-sum-average-max-min/

sum, average, max and min work on a list of numbers. max and min also work on a list of dates and return the latest or the earliest one. Typical uses are story points of subtasks, or the newest comment date.

## Syntax

```
{{list.sum}}
{{list.average}}
{{list.max}}
{{list.min}}
```

## Works on

- Fields: a list of numbers, such as the story points of subtasks, or a list of dates for max and min.
- Returns: one number, or one date for max and min on dates.

## Examples

```
{{issue.summary.replace("Hello World!","3,5,8").split(",").sum}}
```

Add three numbers. Replacing the summary with a literal text gives a list to practise on.

Result:

```
16
```

Run on Jira Cloud on 29 Nov 2026.

```
{{issue.summary.replace("Hello World!","3,5,8").split(",").average}}
```

Average the same list. The result is a decimal number.

Result:

```
5.333333333333333
```

Run on Jira Cloud on 29 Nov 2026.

```
{{issue.summary.replace("Hello World!","3,5,8").split(",").max}}
```

Find the largest value.

Result:

```
8
```

Run on Jira Cloud on 29 Nov 2026.

```
{{issue.summary.replace("Hello World!","3,5,8").split(",").min}}
```

Find the smallest value.

Result:

```
3
```

Run on Jira Cloud on 29 Nov 2026.

```
{{#=}}{{issue.summary.replace("Hello World!","3,5,8").split(",").sum}} * 2{{/}}
```

Use the sum inside a math expression, for example to double the total of the estimates.

Result:

```
32
```

Run on Jira Cloud on 29 Nov 2026.

```
{{issue.comments.created.max}}
```

Get the time of the newest comment: max on dates returns the latest one.

Result:

```
2026-11-29T16:26:59.8+0000
```

Run on Jira Cloud on 29 Nov 2026.

## Pitfalls

- An empty list sums to 0 and averages to 0.0, so a work item without subtasks looks like a total of zero (checked on Jira Cloud, November 2026). `{{issue.subtasks.Story Points.sum}}` prints 0 when there are no subtasks. Test with isEmpty first if zero and nothing differ for you.
- max on an empty list of dates is an empty string, as is `{{issue.fixVersions.releaseDate.min}}` on a work item without versions.
- sum on a list of text values gives an empty string: `{{issue.labels.sum}}` prints nothing. Only numbers add up.

## Related

- [size and isEmpty on lists](https://goingstellar.ro/reference/smart-values/list-size-isempty/)
- [{{#=}} math expressions](https://goingstellar.ro/reference/smart-values/math-expressions/)
- [first, last, get(), getFromEnd()](https://goingstellar.ro/reference/smart-values/list-first-last-get/)
- [isAfter(), isBefore(), isEquals(), compareTo()](https://goingstellar.ro/reference/smart-values/date-compare/)
- [split()](https://goingstellar.ro/reference/smart-values/split/)

## Sources

- [Jira smart values: lists (Atlassian Support)](https://support.atlassian.com/cloud-automation/docs/jira-smart-values-lists/)

