This question evaluates understanding of real-time stream processing, sliding-window aggregation, handling out-of-order events, checksum validation, and algorithmic complexity management for time-bounded data streams.
Design an event processor for an infinite out-of-order event stream (id, timestamp, payload, checksum). Validate checksum, discard events arriving outside a 60-second window, and maintain the average payload length over the current 1-minute sliding window with overall time complexity O(n log n).