Courseiva
Design and implement build and release pipelineshardMultiple ChoiceObjective-mapped

AZ-400 Practice Question: Design and implement build and release pipelines

Exhibit

Refer to the exhibit.

```json
{
  "parameters": {
    "environmentName": {
      "type": "string",
      "defaultValue": "dev"
    },
    "vmSku": {
      "type": "string",
      "defaultValue": "Standard_DS2_v2"
    }
  },
  "variables": {
    "vnetName": "[concat('vnet-', parameters('environmentName'))]"
  },
  "resources": [
    {
      "type": "Microsoft.Network/virtualNetworks",
      "apiVersion": "2023-11-01",
      "name": "[variables('vnetName')]",
      "properties": {
        "addressSpace": {
          "addressPrefixes": [
            "10.0.0.0/16"
          ]
        }
      }
    }
  ]
}
```

Refer to the exhibit. You are deploying this ARM template using Azure Pipelines. The pipeline passes the parameter 'environmentName' with value 'prod'. What will be the name of the virtual network?

⚠ Common exam trap

It's easy for candidates to assume the parameter's default value ('dev') is used instead of recognizing that the pipeline explicitly overrides it with 'prod', leading them to incorrectly select 'vnet-dev'.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

vnet-prod

The ARM template uses the `concat` function to combine the string 'vnet-' with the value of the `environmentName` parameter. Since the pipeline passes 'prod' for `environmentName`, the resulting virtual network name is 'vnet-prod'. This is a standard pattern for parameterizing resource names in Azure Resource Manager templates.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • vnet-default

    Why it's wrong here

    The variable is constructed by concatenating the literal 'vnet-' with the environment parameter value. Since the parameter's default value is 'prod' (and the deployment explicitly uses 'prod'), there is no scenario where the default or supplied value would be 'default', so 'vnet-default' cannot be produced.

  • vnet-prod

    Why this is correct

    The ARM template variable expression uses string concatenation to join the prefix 'vnet-' with the value of the environment parameter. Because the parameter is set to (or defaults to) 'prod', the variable correctly resolves to 'vnet-prod', which is the intended name for the virtual network.

  • vnet-prod-vnet

    Why it's wrong here

    The variable expression is exactly 'vnet-' followed by the parameter value; it does not append any additional text or repeat the parameter name. Therefore, 'vnet-prod-vnet' would incorrectly include an extra 'vnet' suffix that is not part of the concatenation logic in the template.

  • vnet-dev

    Why it's wrong here

    This deployment explicitly specifies (or relies on the default of) the environment parameter as 'prod', not 'dev'. The variable is bound to that parameter value, so the resulting string is 'vnet-prod'; any value like 'vnet-dev' would require the parameter to be 'dev', which is not the case in this deployment.

About these practice questions

This AZ-400 question is part of Courseiva's 823-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This AZ-400 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-400 exam.