1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
|
hi(sample) hi(shuffle)
itemization(
it() Header file: tt(<algorithm>)
it() Function prototype:
itemization(
itt(OutputIterator sample(InputIterator first, InputIterator last,
OutputIterator out, size_t sampleSize,
Generator &&generator);)
)
it() Description:
itemization(
it() tt(sampleSize) elements are randomly selected (without
replacement) from the input range rangett(first, last), and copied to the
destination range starting at tt(out) and ending at the function's return
value. If tt(sampleSize >= (last - first)) all elements are selected. The
tt(generator) is a (uniform) random number generator, like the ti(mt19937)
mercenne twister.
)
See also ti(shuffle):
(url(cppreference)(https://en.cppreference.com)).
it() Example:
verbinclude(-as4 examples/sample.cc)
)
|