Company: Cisco_Code with Cisco_26 june 2026

Difficulty: medium

Problem Statement

Train Reservation Reroute Auditor A national rail operator runs a single high-speed line with M consecutive segments numbered 1..M . Throughout the day, N reservation events arrive in chronological order. There are two event kinds: BOOK l r p : a passenger has booked a journey across segments [l, r] and is charged a per-segment cost contribution of p . After this event, every segment in [l, r] increases its cumulative cost by p . QUERY l r : ask for the minimum cumulative cost among segments in [l, r] as of right now — i.e., reflecting all preceding BOOK events. The auditor wants to replay the day's log and emit one answer for every QUERY. It must also produce one final value, the threshold-event index t* : the earliest event index t such that, after the first t events have been applied, some segment's cumulative cost has reached or exceeded the threshold T (i.e. is ≥ T ). If no segment ever reaches T , output -1 . This value is always required — it is emitted on every run

More Cisco_Code with Cisco_26 june 2026 OA questionsInterview experiences