ITK  4.8.0
Insight Segmentation and Registration Toolkit
SphinxExamples/src/Core/Common/MersenneTwisterRandomIntegerGenerator/Code.cxx
int main(int, char*[])
{
GeneratorType::Pointer generator = GeneratorType::New();
generator->Initialize();
// Get an int between 0 and 5
// (inclusive - that is sample from the set {0,1,2,3,4,5})
std::cout << generator->GetIntegerVariate(5) << std::endl;
return EXIT_SUCCESS;
}