Lesson 12 of 21
1. How to Approach a Design Question

1.11 How do you talk about trade-offs?

3 min read+10 XP

At the architect's desk: "I gave you big windows because you wanted light. The cost is that the room heats up in summer. Unless you'd rather stay cool, then I'd use smaller windows and a skylight." The family trusts her because she names the downside herself.

In the interview: Every design choice gives something and takes something. A trade-off is saying both out loud. Use one sentence pattern:

"I chose ___ because ___. The cost is ___. Unless ___, in which case I'd switch to ___."

A real one from the URL shortener:

"I'll return a 302 (temporary) redirect because every click then passes through our servers, so we can count clicks. The cost is more traffic to our servers than a 301 (permanent) redirect, which browsers can remember and skip us on repeat clicks. Unless analytics doesn't matter, in which case a 301 cuts our load."

You don't need a trade-off for every box. Do it for the big decisions: the database, the caching, consistency, and anything the interviewer questions.

Memory code: "Because, Cost, Unless." Every big choice gets all three.