The Yahtzee Scorer
A medium Python mock interview question on DataDriven. Practice with AI-powered feedback, real code execution, and a hire/no-hire decision.
- Domain
- Python
- Difficulty
- medium
- Seniority
- L3
Interview Prompt
Given 5 dice and a category string, return the score. Categories: 'ones'..'sixes' (sum of dice matching that face), 'three_of_a_kind' (sum of all dice if at least 3 dice share a face, else 0), 'four_of_a_kind' (sum if >=4 share), 'full_house' (25 if 3 of one + 2 of another, else 0), 'small_straight' (30 if 4 consecutive faces), 'large_straight' (40 if 5 consecutive), 'yahtzee' (50 if all 5 same), 'chance' (sum of all 5).
Summary
Dice scoring. Multiple categories evaluated.
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