collections.SymDiff
Returns a slice containing the symmetric difference of two given slices.
- Syntax
- SLICE1 | collections.SymDiff SLICE2
- Returns
- []any
- Alias
- symdiff
Example:
{{ slice 1 2 3 | symdiff (slice 3 4) }} → [1 2 4]Also see https://en.wikipedia.org/wiki/Symmetric_difference.
Last updated:
February 14, 2026
:
Merge commit '8f3c066d23f431fb2c53d97ea489e4c28b42bd82' (3e2f98235)
Improve this page