I'm generating random numbers in C++11. When I run my code
using namespace std;
static std::mt19937_64 rng;
int main() {
rng.seed(11);
std::cout << rng() << std::endl;
}
It returns random numbers. However, I would like to restrict this to a range of numbers, say 1-1000. How would I do this, using the new <random>
file/library introduced in C++11?