Question 13 — AZ-104 Practice Exam 7
For each statement below, indicate whether the answer is True or False
| Item | True | False |
|---|---|---|
| An Azure Policy rule is composed of an if block (conditions) and a then block (effect). | □ | □ |
| The utcNow() function in Azure Policy can only appear in a parameter’s defaultValue. | □ | □ |
| The current() function can be used anywhere in a policy rule to read the current array member. | □ | □ |
| The Field() function returns the value of a property from the resource being evaluated and is commonly used with auditIfNotExists/deployIfNotExists. | □ | □ |
Correct answers
- An Azure Policy rule is composed of an if block (conditions) and a then block (effect). → True
- The utcNow() function in Azure Policy can only appear in a parameter’s defaultValue. → False
- The current() function can be used anywhere in a policy rule to read the current array member. → False
- The Field() function returns the value of a property from the resource being evaluated and is commonly used with auditIfNotExists/deployIfNotExists. → True
Explanations
True: An Azure Policy rule always has if (conditions) and then (effect) sections.
False: In Azure Policy, utcNow() may be used outside defaultValue and returns an ISO 8601 timestamp string.
False: current() is restricted to use inside count expressions to reference the array member under evaluation.
True: Field(fieldName) retrieves a property from the evaluated resource and is frequently used with auditIfNotExists and deployIfNotExists.
An Azure Policy rule is composed of an if block (conditions) and a then block (effect).
The utcNow() function in Azure Policy can only appear in a parameter’s defaultValue.
The current() function can be used anywhere in a policy rule to read the current array member.
The Field() function returns the value of a property from the resource being evaluated and is commonly used with auditIfNotExists/deployIfNotExists.