Update library/core/src/slice/mod.rs
Co-authored-by: Ibraheem Ahmed <ibraheem@ibraheem.ca>
This commit is contained in:
parent
ecf68f3cd0
commit
d39d0ecd57
1 changed files with 1 additions and 1 deletions
|
@ -3102,7 +3102,7 @@ impl<T> [T] {
|
||||||
/// ```
|
/// ```
|
||||||
/// let mut v = [-5i32, 4, 2, -3, 1];
|
/// let mut v = [-5i32, 4, 2, -3, 1];
|
||||||
///
|
///
|
||||||
/// // Find the items `<=` the median, the median, and `>=` the median.
|
/// // Find the items `<=` to the median, the median itself, and the items `>=` to it.
|
||||||
/// let (lesser, median, greater) = v.select_nth_unstable(2);
|
/// let (lesser, median, greater) = v.select_nth_unstable(2);
|
||||||
///
|
///
|
||||||
/// assert!(lesser == [-3, -5] || lesser == [-5, -3]);
|
/// assert!(lesser == [-3, -5] || lesser == [-5, -3]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue