stalin-sort 1.0.2

An implementation of stalin sort in rust.
Documentation
  • Coverage
  • 50%
    2 out of 4 items documented0 out of 3 items with examples
  • Size
  • Source code size: 36.55 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.08 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 50s Average build duration of successful builds.
  • all releases: 22s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • skythedragonn

stalin-sort

An implementation of Stalin Sort, the only O(1) sorting algorithm, which works by sending all out-of order elements to the gulag. Implement Stalin using the StalinSortable trait, or use the prebuilt implementation for Vec. Because of pretentions about 'not discarding data', and 'safety', so we do not mutate your naughty, unsorted lists and simply return a ideal, sorted copy. If you truly wish to take in the naughty, out-of-order elements however (or just punish them further), a version of the method that returns the elements who were sent to the gulag is also provided.