The Price Bander
A easy Python interview practice problem on DataDriven. Write and execute real python code with instant grading.
- Domain
- Python
- Difficulty
- easy
- Seniority
- L4
Problem
Given a dict mapping product names to prices, return a new dict mapping each product name to 'low' (price < 10), 'mid' (price < 50), or 'high' (otherwise).
Summary
Different prices, different treatment.
Practice This Problem
Solve this Python problem with real code execution. DataDriven runs your Python code in a real environment and grades it automatically.