Python data engineering interview problem. Difficulty: beginner. Pattern: Dictionaries. About 10 minutes. Part of the Pro drill bank.
Forklifts scan a warehouse zone each time they enter it. A heatmap needs how many visits each zone received.
Count visits per warehouse zone.
Input: zone_visit_counts(['A', 'B', 'A', 'C', 'B', 'A']) Output: [('A', 3), ('B', 2), ('C', 1)] This input follows the stated rules and produces this output.
Topics: lakebench, python, dictionaries.
More Python interview questions · All interview problems · Learn data engineering
Interview-style drill: Given a sequence of warehouse zone visits, return each zone's visit count sorted by frequency.
Count visits per warehouse zone.