random_shuffle()
By default, random_shuffle() reorders the elements randomly based on its own algorithm. An optional third parameter allows us to pass in a random-number-generating operation that must return a value of type double within the interval [0,1].
#include <algorithm>
random_shuffle( ivec.begin(), ivec.end() );
|