Say you have a server that constantly gets HTTP requests. Your boss needs some stats, and asks you to compute the number of hits within the last minute at any given time.
What algorithm and data-structure would you use to achieve this?
Say you have a server that constantly gets HTTP requests. Your boss needs some stats, and asks you to compute the number of hits within the last minute at any given time.
What algorithm and data-structure would you use to achieve this?