pub trait SelectionSort<T: PartialEq + PartialOrd + Clone + Copy> {
    fn selection_sort(&mut self);
fn selection_sort_timed(&mut self) -> Duration;
fn selection_sort_stepped(&mut self) -> Vec<(Vec<T>, Vec<T>)>;
fn selection_sort_stepped_and_timed(
        &mut self
    ) -> (Vec<(Vec<T>, Vec<T>)>, Duration); }
Expand description

A trait providing the selection sort algorithm.

Required methods

The selection sort algorithm.

Sorts the Vec it is called on.

The selection sort algorithm but timed.

Sorts the Vec it is called on and returns the Duration of the process.

The selection sort algorithm but stepped.

Sorts the Vec it is called on and returns a Vec containing each step of the process.

The selection sort algorithm but stepped and timed.

Sorts the Vec it is called on and returns a Vec containing each step of the process, including the Duration of the entire process.

Implementations on Foreign Types

The trait implementation of the selection sort algorithm.

Implementors