The Column Shuffle
A medium Python 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
- Python
- Difficulty
- medium
- Seniority
- L6
Interview Prompt
A long-format metrics export gives you one record per reading, each carrying an `id` and a single `amount`, and the same `id` can recur across many records. Return one dict per id holding its `id` and its amounts spread across numbered keys like `amount_1`, `amount_2`.
Summary
Rows in, columns out. Number them.
How This Interview Works
- Read the vague prompt (just like a real interview)
- Ask clarifying questions to the AI interviewer
- Write and run your Python against test cases
- Answer the interviewer's follow-up questions, then get a hire or no-hire decision