Code RoomIn-house feature flags
HardPrep Room Coding #4265

In-house feature flags

Vibe & agenticAlgorithms & data structuresSenior–Staff~28 min

You're building an in-house feature-flag system in TypeScript from scratch (no LaunchDarkly) with an AI agent: a flag store, a percentage-rollout + targeting-rules evaluator, an SDK for services to read flags, and an admin API. Describe how you'd decompose this for the agent, what you delegate vs. own, the acceptance criteria for the evaluation engine, and where the review gates go. What does a careless 'build a feature flag service' prompt get subtly wrong?

Implement
evaluate_flag_for_users(flag_key: str, user_ids: list[str], rollout_percent: int, targeted_user_ids: list[str]) → list[bool]
Examples
in["checkout_v2",["u1","u2","u3"],100,[]]out[true,true,true]
in["checkout_v2",["u1","u2","u3"],0,["u2"]]out[false,true,false]
What a strong answer looks like

Treat the AI’s output as a draft to verify, not an answer to trust. Name the specific flaw and the input that triggers it, say how you’d catch it (tests, edge cases, reading critically), and how you’d re-prompt or decompose to get it right.

0:00 of about 28 min

Vibe & agentic: describe the solution in plain language (or narrate it) and the coach grades your approach.

Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.