nerdexam
HashiCorp

TA-002-P · Question #172

Which of the below datatype is not supported by Terraform.

The correct answer is A. Array. Terraform does not have a native 'array' type; its collection types are list, map, set, object, and tuple.

Understand Terraform basics

Question

Which of the below datatype is not supported by Terraform.

Options

  • AArray
  • BList
  • CObject
  • DMap

How the community answered

(50 responses)
  • A
    88% (44)
  • B
    2% (1)
  • C
    2% (1)
  • D
    8% (4)

Why each option

Terraform does not have a native 'array' type; its collection types are list, map, set, object, and tuple.

AArrayCorrect

Terraform's type system includes primitive types (string, number, bool) and collection/structural types (list, map, set, object, tuple) - there is no 'array' type, making it the unsupported type among the choices.

BList

List is a fully supported Terraform collection type representing an ordered sequence of values that share the same type.

CObject

Object is a valid Terraform structural type that groups named attributes which can each have different types.

DMap

Map is a valid Terraform collection type representing key-value pairs where all values share the same type.

Concept tested: Terraform supported primitive and collection data types

Source: https://developer.hashicorp.com/terraform/language/expressions/types

Topics

#Terraform data types#HCL#Configuration language

Community Discussion

No community discussion yet for this question.

Full TA-002-P Practice