Crate bisection
Source pub use crate::bisect_right as bisect;
pub use crate::insort_right as insort;
- bisect_left
- Return the index where
x
should be inserted in a
, assuming a
is sorted. - bisect_left_by
- Return the index where a value should be inserted in
a
, assuming a
is sorted, according to
a comparator function. - bisect_left_slice
- Return the index where
x
should be inserted in a[within]
, assuming a
is sorted. - bisect_left_slice_by
- Return the index where a value should be inserted in
a[within]
, assuming it sorted,
according to a comparator function. - bisect_right
- Return the index where
x
should be inserted in a
, assuming a
is sorted. - bisect_right_by
- Return the index where
x
should be inserted in a
, assuming a
is sorted, according to
a comparator function. - bisect_right_slice
- Return the index where
x
should be inserted in a[within]
, assuming a
is sorted. - bisect_right_slice_by
- Return the index where a value should be inserted in
a[within]
, assuming it sorted,
according to a comparator function. - insort_left
- Insert
x
in a
, keeping it sorted assuming a
is sorted. - insort_left_by
- Insert
x
in a
, keeping it sorted, assuming a
is sorted, according to a comparator
function. - insort_left_slice
- Insert
x
in a[within]
, keeping it sorted assuming a
is sorted. - insort_left_slice_by
- Insert x in
a[within]
, keeping it sorted, assuming a
is sorted, according to a comparator
function. - insort_right
- Insert
x
in a
, keeping it sorted assuming a
is sorted.
If a
contains x
, insert it just after the rightmost occurence of x
. - insort_right_by
- Insert
x
in a
, keeping it sorted, assuming a
is sorted, according to a comparator
function. - insort_right_slice
- Insert
x
in a[within]
, keeping it sorted assuming a
is sorted. - insort_right_slice_by
- Insert x in
a[within]
, keeping it sorted, assuming a
is sorted, according to a comparator
function.