Pergunta de entrevista da empresa Box

The coding task is about reading numbers from a CSV file, computing a rolling window statistics (average and maximum) over those numbers, and printing current statistics at every time step. It should be done in O(nlogn) time. To do it data structures like (in Java) TreeMap or PriorityQueue come handy. Unfortunately there's little time to do it (slightly more than an hour). Although I had idea how to do it, I stressed out and I failed to meet the O(nlogn) time in all cases, and only based on it I was rejected.