Predict the output
What do the two lines print?
slo = 0.999
minutes_30_days = 30 * 24 * 60
budget = (1 - slo) * minutes_30_days
print(round(budget, 1))
error_rate = 0.0144 # observed over the last hour
burn = error_rate / (1 - slo)
print(round(burn, 1))Hint 1 of 1
1 − 0.999 = 0.001
Choose an answer, then open Show answer below to check it.
Show answer
Answer: A 43.2 then 14.4
Correct. 0.1% of 43,200 minutes, and an error rate 14.4× the allowed 0.1%.
A 99.9% SLO allows 0.1% failure: 43.2 of the 43,200 minutes in 30 days. Burn rate is the observed error rate divided by that allowance, and 14.4× would use a month's budget in about two days.
Why not the others?
- B
43.2then1.4. 0.0144 / 0.001 is 14.4. - C
4.3then14.4. 30 days is 43,200 minutes. - D
432.0then144.0. The budget is 0.1%, not 1%.