RandSet
A hash set that supports efficient random element access.
RandSet combines the fast lookup of a hash set with the ability to
efficiently retrieve random elements, using the get_rand() method.
rest of the method work the same as a HashSet https://doc.rust-lang.org/std/collections/struct.HashSet.html
Key Differences from Standard Sets
Unlike a regular HashSet, elements stored in RandSet must implement the
Clone trait.
All other methods
work like a regular set (insertion, removal, containment checking, etc.).
Example
use RandSet;
let mut set = new;
set.insert;
set.insert;
// Fast containment check (works like HashSet)
assert!;
// Unique feature: Get a random element in O(1)
if let Some = set.get_rand