def overlap(span, spans):
    """Determine whether span overlaps with anything in spans."""
    return any(
        start <= span[0] < end or start < span[1] <= end
        for start, end in spans
    )