Microsoft AZ-200 Exam Practice Questions (P. 5)
- Full Access (63 questions)
- Six months of Premium Access
- Access to one million comments
- Seamless ChatGPT Integration
- Ability to download PDF files
- Anki Flashcard files for revision
- No Captcha & No AdSense
- Advanced Exam Configuration
Question #21
DRAG DROP -
You have an Azure subscription.
You must create a file share with a quota of 2,048 GB. You create the following variables.

In which order should you arrange the Azure CLI commands to develop the solution? To answer, move all the commands from the list of commands to the answer area and arrange them in the correct order.
Select and Place:
You have an Azure subscription.
You must create a file share with a quota of 2,048 GB. You create the following variables.

In which order should you arrange the Azure CLI commands to develop the solution? To answer, move all the commands from the list of commands to the answer area and arrange them in the correct order.
Select and Place:
Correct Answer:
Explanation
Step 1: az group create -
The resource group will be used when you create the storage account in step 2.
Step 2: Az storage account create
To use Azure Storage, you need a storage account. You can create a new Azure Storage account after you've configured your computer to connect to your subscription. az storage account create \
--location <location> \
--name <account_name> \
--resource-group <resource_group> \
--sku <account_sku>
Step 3: az storage account keys -
Set default Azure storage account environment variables
You can have multiple storage accounts in your Azure subscription. To select one of them to use for all subsequent storage commands, you can set these environment variables:
First, display your storage account keys by using the az storage account keys list command
Step 4: Az storage share create -
References:
https://docs.microsoft.com/en-us/azure/storage/common/storage-azure-cli
Explanation
Step 1: az group create -
The resource group will be used when you create the storage account in step 2.
Step 2: Az storage account create
To use Azure Storage, you need a storage account. You can create a new Azure Storage account after you've configured your computer to connect to your subscription. az storage account create \
--location <location> \
--name <account_name> \
--resource-group <resource_group> \
--sku <account_sku>
Step 3: az storage account keys -
Set default Azure storage account environment variables
You can have multiple storage accounts in your Azure subscription. To select one of them to use for all subsequent storage commands, you can set these environment variables:
First, display your storage account keys by using the az storage account keys list command
Step 4: Az storage share create -
References:
https://docs.microsoft.com/en-us/azure/storage/common/storage-azure-cli
send
light_mode
delete
Question #22
HOTSPOT -
You have an app that stores player scores for an online game. The app stores data in Azure tables using a class named PlayerScore as the table entity. The table is populated with 100,000 records.
You are reviewing the following section of code that is intended to retrieve 20 records where the player score exceeds 15,000. (Line numbers are included for reference only.)

For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:

You have an app that stores player scores for an online game. The app stores data in Azure tables using a class named PlayerScore as the table entity. The table is populated with 100,000 records.
You are reviewing the following section of code that is intended to retrieve 20 records where the player score exceeds 15,000. (Line numbers are included for reference only.)

For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:

Correct Answer:
Box 1: No -
Box 2: Yes -
The TableQuery.Take method defines the upper bound for the number of entities the query returns.
Example:
query.Take(10);
Box 3: Yes -
Box 4: Yes -
References:
https://www.vkinfotek.com/azureqa/how-do-i-query-azure-table-storage-using-tablequery-class.html

Box 1: No -
Box 2: Yes -
The TableQuery.Take method defines the upper bound for the number of entities the query returns.
Example:
query.Take(10);
Box 3: Yes -
Box 4: Yes -
References:
https://www.vkinfotek.com/azureqa/how-do-i-query-azure-table-storage-using-tablequery-class.html
send
light_mode
delete
Question #23
DRAG DROP -
You need to upload a video URL to Azure Video Indexer and return the video id.
Which three code segments should you use to complete the solution? To answer, move the appropriate code segments from the code segments to the answer area and arrange them in the correct order.
Select and Place:
You need to upload a video URL to Azure Video Indexer and return the video id.
Which three code segments should you use to complete the solution? To answer, move the appropriate code segments from the code segments to the answer area and arrange them in the correct order.
Select and Place:
Correct Answer:
Explanation
Step 1: var uploadRequestResult = client.PostAsync($"{apiUrl}/{location}/Accounts/{accountId}/Videos?accessToken={accountAccessToken}
&name=some_name&description=some_description&privacy=private&partition=some_partition&videoUrl={videoUrl}", content).Result;
Step 2: var uploadResult = uploadRequestResult.Content.ReadAsStringAsync().Result;
Step 3: var videoId = JsonConvert.DeserializeObject<dynamic>(uploadResult)["id"];
Get the video id from the upload result.
References:
https://docs.microsoft.com/en-us/azure/media-services/video-indexer/video-indexer-use-apis
Explanation
Step 1: var uploadRequestResult = client.PostAsync($"{apiUrl}/{location}/Accounts/{accountId}/Videos?accessToken={accountAccessToken}
&name=some_name&description=some_description&privacy=private&partition=some_partition&videoUrl={videoUrl}", content).Result;
Step 2: var uploadResult = uploadRequestResult.Content.ReadAsStringAsync().Result;
Step 3: var videoId = JsonConvert.DeserializeObject<dynamic>(uploadResult)["id"];
Get the video id from the upload result.
References:
https://docs.microsoft.com/en-us/azure/media-services/video-indexer/video-indexer-use-apis
send
light_mode
delete
Question #24
HOTSPOT -
A company is developing a mobile app for field service employees using Azure App Service Mobile Apps as the backend.
The company's network connectivity varies throughout the day. The solution must support offline use and synchronize changes in the background when the app is online again.
You need to implement the solution.
How should you complete the code segment? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
A company is developing a mobile app for field service employees using Azure App Service Mobile Apps as the backend.
The company's network connectivity varies throughout the day. The solution must support offline use and synchronize changes in the background when the app is online again.
You need to implement the solution.
How should you complete the code segment? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Correct Answer:
Explanation
Box 1: var todoTable = client GetSyncTable<TodoItem>()
To setup offline access, when connecting to your mobile service, use the method GetSyncTable instead of GetTable (example):
IMobileServiceSyncTable todoTable = App.MobileService.GetSyncTable(); /
Box 2: await todoTable.PullAsync("allTodoItems",todo.Table.CreateQuery());
Your app should now use IMobileServiceSyncTable (instead of IMobileServiceTable) for CRUD operations. This will save changes to the local database and also keep a log of the changes. When the app is ready to synchronize its changes with the Mobile Service, use the methods PushAsync and PullAsync (example): await App.MobileService.SyncContext.PushAsync(); await todoTable.PullAsync();
References:
https://azure.microsoft.com/es-es/blog/offline-sync-for-mobile-services/
Explanation
Box 1: var todoTable = client GetSyncTable<TodoItem>()
To setup offline access, when connecting to your mobile service, use the method GetSyncTable instead of GetTable (example):
IMobileServiceSyncTable todoTable = App.MobileService.GetSyncTable(); /
Box 2: await todoTable.PullAsync("allTodoItems",todo.Table.CreateQuery());
Your app should now use IMobileServiceSyncTable (instead of IMobileServiceTable) for CRUD operations. This will save changes to the local database and also keep a log of the changes. When the app is ready to synchronize its changes with the Mobile Service, use the methods PushAsync and PullAsync (example): await App.MobileService.SyncContext.PushAsync(); await todoTable.PullAsync();
References:
https://azure.microsoft.com/es-es/blog/offline-sync-for-mobile-services/
send
light_mode
delete
Question #25
You maintain an Azure Web App that runs in a container. The container is using a Dockerfile that is copied to numerous places and consumes a large amount of storage.
You need to optimize the Dockerfile.
What should you do?
You need to optimize the Dockerfile.
What should you do?
- AMinimize layers by grouping actions in as few RUN instructions as possible.
- BUse multiple RUN instructions for cached operation.
- CMinimize layers by concatenating all RUN instructions on one line.
- DConfigure the CLI with a .dockerignore file.
Correct Answer:
A
Minimize the number of layers.
Prior to Docker 17.05, and even more, prior to Docker 1.10, it was important to minimize the number of layers in your image.C
In Docker 1.10 and higher, only RUN, COPY, and ADD instructions create layers.
References:
https://docs.docker.com/v17.09/engine/userguide/eng-image/dockerfile_best-practices
A
Minimize the number of layers.
Prior to Docker 17.05, and even more, prior to Docker 1.10, it was important to minimize the number of layers in your image.C
In Docker 1.10 and higher, only RUN, COPY, and ADD instructions create layers.
References:
https://docs.docker.com/v17.09/engine/userguide/eng-image/dockerfile_best-practices
send
light_mode
delete
All Pages