#random #order #iterate #values #data-structures #set #allocating

shuffled-iter

Iterate through a set of values in random order without allocating them all

2 unstable releases

Uses old Rust 2015

0.2.0 Sep 4, 2016
0.1.0 Aug 9, 2015

#2904 in Algorithms

Download history 1/week @ 2024-12-04 8/week @ 2024-12-11 1/week @ 2024-12-18 10/week @ 2025-02-05 52/week @ 2025-02-12 9/week @ 2025-02-26

71 downloads per month

MIT license

11KB
236 lines

shuffled-iter Build Status Coverage Status Crates.io

Documentation

This crate provides methods to iterate over a group of values in random order, without allocation and shuffling them all.

It currently supports:

  • all integer ranges
  • slices of any kind

lib.rs:

This crate provides methods to iterate over a group of values in random order, without allocation and shuffling them all.

Such an iterator may be obtained via the ShuffledIterGen trait.

Dependencies

~1.5MB
~18K SLoC