def closest_points_are_within_length(targets_distance, N, length):
    """
    :param targets_dist: iterable of the form [(lat, lon), dist]
    :param N: strictly positive integer
    :param length: positive number
    :return: boolean, whether the distance from source to the N-th point in targets_dist is leq to length
    """
    return targets_distance[:N][-1][1] <= length