← DevOps Foundations
10 / 25
Lesson 10 — Uptime percentage
How reliable is the service?
Uptime is the share of time a service was working: up minutes ÷ total minutes × 100. Teams promise targets in an SLA (service level agreement), such as "99.9%". That sounds high, but 99.9% still allows about 43 minutes of downtime a month. toFixed(2) rounds a number to 2 decimals and returns text.
(1435 / 1440 * 100).toFixed(2) // "99.65"
Why it matters: uptime turns "it feels stable" into a number you can track and promise.
Want it another way?
Task
Compute uptime as a percentage with 2 decimals, and print whether it meets the 99.9% target.
Run your code — when the output matches the task, you will see a green check. Then mark the lesson complete.
Test your knowledge
A quick 3-question quiz on this lesson — instant feedback.