Design a counter of recent requests. ping(t) records a request at time t in milliseconds and returns the number of requests in the inclusive range [t - 3000, t]. Each call uses a strictly larger t than the previous one.
Practise this challenge
All coding challenges