page_title: coalesce - Functions - Configuration Language
page_title: coalesce function reference
description: |-
The coalesce function takes any number of arguments and returns the
first one that isn't null nor empty.
The `coalesce` function returns the first argument that is not empty or `null` from a list of arguments. Learn to use the `coalesce` function in Packer templates.
page_title: coalescelist - Functions - Configuration Language
page_title: coalescelist function reference
description: |-
The coalescelist function takes any number of list arguments and returns the
first one that isn't empty.
The `coalescelist` function returns the first non-empty argument in a list of arguments. Learn how to use the `coalescelist` function in Packer templates.
page_title: contains - Functions - Configuration Language
description: The contains function determines whether a list or set contains a given value.
page_title: contains function reference
description: The `contains` function determines whether a list or set contains a given value. Learn how to use the `contains` function in Packer templates.
page_title: lookup - Functions - Configuration Language
description: The lookup function retrieves an element value from a map given its key.
page_title: lookup function reference
description: The `lookup` function retrieves an element value from a map using the map key. Learn how to use the `lookup` function in Packer templates.
page_title: setintersection - Functions - Configuration Language
page_title: setintersection function reference
description: |-
The setintersection function takes multiple sets and produces a single set
containing only the elements that all of the given sets have in common.
The `setintersection` function creates one set from multiple sets that contains only elements common to all input sets. Learn how to use `setintersection` in Packer templates.
---
# `setintersection` Function
The `setintersection` function takes multiple sets and produces a single set
containing only the elements that all of the given sets have in common.
In other words, it computes the
[intersection](<https://en.wikipedia.org/wiki/Intersection_(set_theory)>) of the sets.
page_title: setunion - Functions - Configuration Language
page_title: setunion function reference
description: |-
The setunion function takes multiple sets and produces a single set
containing the elements from all of the given sets.
The `setunion` function creates one set containing the elements from multiple given sets. Learn how to use the `setunion` function in Packer templates.