hugo/docs/content/en/functions/collections/SymDiff.md
2023-10-20 09:43:56 +02:00

597 B

title linkTitle description categories keywords menu function relatedFunctions aliases
collections.SymDiff symdiff Returns the symmetric difference of two collections.
functions
docs
parent
functions
aliases returnType signatures
symdiff
any
COLLECTION | collections.SymDiff COLLECTION
collections.Complement
collections.Intersect
collections.SymDiff
collections.Union
/functions/symdiff

Example:

{{ slice 1 2 3 | symdiff (slice 3 4) }} → [1 2 4]

Also see https://en.wikipedia.org/wiki/Symmetric_difference