mediumSystem Design

How do you approach back-of-the-envelope capacity estimation?

951 views
01

Understand the problem

Explain estimation in design interviews.

estimation
02

Attempt it yourself

Sketch your approach before reading the solution — that's what interviews test.

Stuck? AI Nudge Available

Get a conceptual hint to guide your logic without spoiling the final implementation.

03

Study the solution

The solution is waiting

Give it an honest attempt first — then compare your thinking with the full walkthrough.

04

Read the code

Quick capacity calculator
Run Playground
DAU = 100_000_000
actions_per_user = 20
seconds_per_day = 86_400
peak_factor = 3

requests_per_day = DAU * actions_per_user
avg_qps  = requests_per_day / seconds_per_day
peak_qps = avg_qps * peak_factor

new_items_per_day = 1_000_000
bytes_per_item = 1_000                       # ~1 KB
storage_5y_tb = new_items_per_day * bytes_per_item * 365 * 5 / 1e12

print("avg QPS        :", round(avg_qps))
print("peak QPS       :", round(peak_qps))
print("5-year storage :", round(storage_5y_tb, 1), "TB")
05

Join the discussion

Discussion (0)

Sign in to join the discussion.

No responses yet. Be the first to share what you think.