adding algorithm explanation for partition_in_place iter method and bounding complexity to current implementation
This commit is contained in:
parent
196050305c
commit
85e4177184
1 changed files with 4 additions and 0 deletions
|
@ -1849,6 +1849,10 @@ pub trait Iterator {
|
|||
///
|
||||
/// The relative order of partitioned items is not maintained.
|
||||
///
|
||||
/// # Current implementation
|
||||
/// Current algorithms tries finding the first element for which the predicate evaluates
|
||||
/// to false, and the last element for which it evaluates to true and repeatedly swaps them.
|
||||
///
|
||||
/// Time Complexity: *O*(*N*)
|
||||
///
|
||||
/// See also [`is_partitioned()`] and [`partition()`].
|
||||
|
|
Loading…
Add table
Reference in a new issue