def compute_increment(draw, a, b):
    """
    From a list of event timestamps in a counting process, count the number of events
    between a and b.

    :param list[float] draw: A list of timestamps drawn from a counting process
    :param float a: The left endpoint
    :param float b: The right endpoint
    :return: The increment between a and b
    :rtype: int
    """
    return sum(1 for d in draw if a < d < b)