discard_block_engine Class

 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at discard_block_engine Class.

Generates a random sequence by discarding values returned by its base engine.

template <class Engine, size_t P, size_t R>  
class discard_block_engine;  

Parameters

Engine
The base engine type.

P
Block size. The number of values in each block.

R
Used block. The number of values in each block that are used. The rest are discarded ( P - R). Precondition: 0 < R ≤ P

discard_block_engine::discard_block_enginediscard_block_engine::basediscard_block_engine::discard
discard_block_engine::operator()discard_block_engine::base_typediscard_block_engine::seed

For more information about engine members, see <random>.

This template class describes an engine adaptor that produces values by discarding some of the values returned by its base engine.

Header: <random>

Namespace: std

<random>

Show: