PCA (Prometheus Certified Associate) sample exam question with answer 254

Question:
The metric http_errors_total{code=”404”} tracks the number of 404 errors a web server has seen.
Which query returns what is the average rate of 404s a server has seen for the past 2 hours? Use a 2m sample range and a query interval of 1m

  1. avg_over_time(rate(http_errors_total{code=”404”}[2m]) [1m:2h])
  2. avg_over_time(rate(http_errors_total{code=”404”}[2m]) [2h:1m])
  3. avg_over_time(rate(http_errors_total{code=”404”}[2m])) [2h:1m]
  4. avg_over_time(rate(http_errors_total{code=”404”}[2h]))
Answer:
B - correct answer