Rare production message loss
A distributed Java service intermittently loses messages under load — maybe one in fifty thousand, only in production, only at peak. Your instinct is to paste the consumer code into an AI agent and ask it to 'find the bug'. Explain when reaching for the AI here is the wrong move, what failure modes make it ineffective, and where (if anywhere) it still earns its place.
Implement
find_lost_offsets(log_lines: list[str]) → list[int]Examples
in
[["recv:1","done:1","commit:1"]]out[]in
[["recv:1","recv:2","done:2","commit:2"]]out[1]in
[["recv:5","commit:3","done:5"]]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 18 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.
Run or narrate your approach, then ask the coach.