Loading interview...
The Password Builder
A easy Python mock interview question on DataDriven. Practice with AI-powered feedback, real code execution, and a hire/no-hire decision.
- Domain
- Python
- Difficulty
- easy
- Seniority
- junior
Interview Prompt
Our provisioning service generates temporary passwords. Write a function called generate_password that takes a length and a character pool string, and builds a password by cycling through the pool. The first character comes from index 0, the second from index 1, and so on, wrapping around when the pool is exhausted. Return the resulting string.
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