Code RoomLock-free ring buffer limits
HardPrep Room Coding #4504

Lock-free ring buffer limits

Vibe & agenticAlgorithms & data structuresSenior–Staff~20 min

You're designing a custom lock-free ring buffer for a low-latency C++ trading component where a subtle memory-ordering bug means lost or duplicated messages under load — and may pass every test for weeks before manifesting. Your junior wants to have the agent generate the whole thing. Would you reach for an AI assistant here, and where exactly does it stop being the right tool?

Implement
classify_delegation_scope(task_names: list[str], tests_catch_it: list[bool], deterministic: list[bool], severity: list[int]) → list[str]
Examples
in[["ring_buffer_core","bench_harness"],[false,true],[false,true],[5,2]]out["ring_buffer_core=own","bench_harness=delegate"]
in[["error_taxonomy"],[true],[true],[4]]out["error_taxonomy=assist"]
in[[],[],[],[]]out[]
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 20 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.