Skip to main content

array_max_min

Function array_max_min 

Source
pub fn array_max_min<T>(arr: &[T]) -> (T, T)
where T: PartialOrd + Copy,
Expand description

Get the maximum and minimum value of an array

§Params

  • arr - The array of values

§Returns

Tuple of (max, min) in the array