Code Room
Vibe codingEasyvc-g591
Subject Ai verificationLevel Entry–Mid~12 minCommon in Algorithms & data structures interviewsIndustries Software development

Question

An AI agent wrote a 40-character Python regex to validate and parse international phone numbers for a signup form, and it works on every example you tried. You don't fully understand the regex — the lookaheads and the optional country-code group are opaque to you. It's about to gate every new user. How do you verify it's correct and safe before merging, without just trusting that it parsed your handful of test numbers correctly?

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.

Describe your solution

Vibe coding: describe the solution in plain language (or narrate it) and the coach grades your approach. Generating runnable code from your description is coming next.

Run or narrate your approach, then ask the coach.