Counted Twice
An easy AI Coding mock interview question on DataDriven, with an AI interviewer who asks follow-up questions and a hire or no-hire decision at the end.
- Domain
- AI Coding
- Difficulty
- easy
- Seniority
- L4
Interview Prompt
Restaurant partners are seeing ~12% inflated revenue in our partner-ping job. The job builds daily_restaurant_revenue from the orders + dropoffs tables. Run tests/test_no_double_count.py to reproduce: rows where one order has multiple dropoffs (multi-stop deliveries) get counted once per dropoff. Fix the SQL in queries/daily_restaurant_revenue.sql so revenue is per order, not per (order, dropoff).
Summary
Twice the revenue, half the truth.
How This Interview Works
- Read the task and the repository: the files, the failing check and the constraints
- Work the fix with the AI agent at your side, and run the checks until they pass
- Submit, then answer the interviewer's questions about the change you made
- Get a hire or no-hire decision with feedback on how you drove the agent