Container-based version of the <algorithm> std::shuffle() function to randomly shuffle elements within the container using a gen() uniform random number generator.
Declared in <absl/algorithm/container.h>
template<
typename RandomAccessContainer,
typename UniformRandomBitGenerator>
void
c_shuffle(
RandomAccessContainer& c,
UniformRandomBitGenerator&& gen);
| Name | Description |
|---|---|
| c | The container whose elements to shuffle. |
| gen | The uniform random bit generator driving the shuffle. |