 for all startTime <= t && t + w <= endTime }.
   * See https://goo.gl/jmWpMl for the description of the algorithm.
   *
   * @param {number} start time for the sliding window.
   * @param {number} end time for the sliding window.
   * @param {number} the size of the sliding window.
   * @param {!Array.<!{start: number, end: number}>} A list of tasks.
   *        The tasks must not overlap.
   * @returns {number}
   */
  function maxExpectedQueueingTimeInSlidingWindow(startTime, endTime,
      windowSize, t