Practice problem

Sensor Alerts

Medium VerkadaAgent round2 stages45 minPython

Water sensors on a basement floor take readings now and then, each a time and a water level, and the caretaker is alerted while the water stands at or above an alert level. You implement the function that returns one sensor's active periods, each a run of readings at or above that level. The second stage finds the periods when every sensor is active at the same time. Candidates report it from Verkada's technical screens.

The stages

Each stage opens once the tests for the one before it pass, and each raises the bar, the way an interviewer does in the room.

  1. Active periods.
  2. Every sensor at once. Several sensors, each reading on its own schedule: find when the whole basement was wet at the same time.

The round: an agent in the editor

The assistant here works like the one in the interview IDE. It reads your files, runs code and proposes changes, and you accept or reject each one. It doesn't volunteer ideas, so what gets built is what you asked for. Along the way the interviewer asks about your decisions, and at the end the report says what you checked and what you accepted unread.

More like it: every practice problem, how Verkada runs its AI round, the AI coding interview guide.