how to use random() function in dev c++?

ow to use random(25) function in dev c++?

which header file will use here?
Last edited on
I've never heard of this function.

C++ supports rand()
http://www.cplusplus.com/reference/cstdlib/rand/

which you shouldn't really use, and the more advanced set of random number generators in random
http://www.cplusplus.com/reference/random/

i use header file <random>
but unfortunatly an error occurs

#error This file requires compiler and library support for the \
ISO C++ 2011 standard. This support is currently experimental, and must be \
enabled with the -std=c++11 or -std=gnu++11 compiler options.

do you have solution of this error?
The solution is stated in the error message: use the -std=c++11 compiler flag.
Topic archived. No new replies allowed.