code: public List<Long> getSlidingCountTimestamps(long startTs, long endTs, int slidingCount) {
          List<Long> timestamps = new ArrayList<>();
          if (endTs > startTs) {
              int count = 0;
              long ts = Long.MIN_VALUE;
              for (Event<T> event : queue) {
                  if (event.getTimestamp() > startTs && event.getTimestamp() <= endTs) {
                      ts = Math.max(ts, event.getTimestamp());
                      if (++count % slidingCount == 0) {
                          timestamps.add(ts);
                      }
                  }
              }
          }
          return timestamps;
      }
docs: Scans the event queue and returns the list of event ts
  falling between startTs (exclusive) and endTs (inclusive)
  at each sliding interval counts.
  
  @param startTs the start timestamp (exclusive)
  @param endTs the end timestamp (inclusive)
  @param slidingCount the sliding interval count
  @return the list of event ts