Crates.io | sorting |
lib.rs | sorting |
version | 1.2.0 |
source | src |
created_at | 2017-11-14 14:56:28.77599 |
updated_at | 2019-10-30 13:28:02.773583 |
description | The world's best, finest and inefficient sorting algorithms. |
homepage | https://github.com/feliix42/sorting-rs |
repository | https://github.com/Feliix42/sorting-rs |
max_upload_size | |
id | 39323 |
size | 33,284 |
This crate only implements the most useless or inefficient sorting algorithms. You may use them in your production application, altough I would strongly advise against that. Currently, the following sorting algorithms are implemented:
If you feel like this list misses some fancy algorithm (which it surely does!), you can implement it and open a PR or open an issue. :)
Honestly, I did not think much of this at the time this was conceived. But if you think you have a more valid use for this crate name, please do get in touch with me so that we can work something out!
All algorithms are currently implemented as traits for any Vec<T>
where T
fulfills the trait PartialOrd
.
So in order to use these sorting alrogithms, you can just invoke them on the object of interest:
use sorting::*;
let unsorted = vec![5, 7, 8, 2, 1, 0];
unsorted.panicsort(); // will panic
Using the respective traits you can always implement these methods for your own structures.
This work is licensed under the Mozilla Public License 2.0.