Microsoft Certified Azure Developer Associate · Free Practice Question Easy

Question 2

You need to configure an Azure Function to run on a schedule using a CRON expression. Your requirement is to have the function execute at 5 minutes past every hour, every day of the week. Which of the following CRON expressions should you use?

  • A

    5 * * * *

  • B

    0/5 * * * *

  • C

    0 5 * * *

  • D

    5 * * * 1-5

Reveal correct answer

Correct answer: A

A. The CRON expression "5 * * * *" specifies that the function should execute at 5 minutes past every hour, every day of the week. The "*" wildcard character in the second and subsequent fields ensures that the function runs every hour, every day of the week, while the "5" in the first field specifies the 5th minute of each hour for execution.

B. The CRON expression "0/5 * * * *" specifies that the function should run every 5 minutes. This does not meet the requirement of executing the function at 5 minutes past every hour, every day of the week.

C.

The CRON expression "0 5 * * *" specifies that the function should execute at 5 hours past midnight (i.e. 5:00AM) every day. This expression does not meet the requirement of running the function at 5 minutes past every hour, every day of the week.

D. The CRON expression "5 * * * 1-5" specifies that the function should execute at 5 minutes past every hour, only on Monday to Friday. This expression does not meet the requirement of running the function every day of the week.

Discussion

Think the marked answer is wrong, or have a better explanation? Share it below — comments appear after review.

You must be logged in to post a comment.

Preparing For

Your Certification?

255+ certifications
Detailed explanations
Free PDF samples

Has All The Questions You Need