Moving Day
A hard Python mock interview question on DataDriven. Practice with AI-powered feedback, real code execution, and a hire/no-hire decision.
- Domain
- Python
- Difficulty
- hard
- Seniority
- L5
Interview Prompt
A schema migration is an ordered list of operations run against every stored record: `rename` a field, `add` one with a default, `remove` one, or `cast` a field to `int`, `float`, or `str`. A field's `path` is dot-separated so an operation can reach into a nested record like `addr.country`, and `add` builds any intermediate records that are missing while `rename`, `remove`, and `cast` skip a path that isn't there. Casting is lenient: a value that will not convert, such as `None`, is left as it is.
Summary
Old schema in, new schema out.
How This Interview Works
- Read the vague prompt (just like a real interview)
- Ask clarifying questions to the AI interviewer
- Write your python solution with real code execution
- Get instant feedback and a hire/no-hire decision