0
Can anyone tell me
Name of the header file needed for using randomize() in solo learn app
2 Answers
+ 2
You will need to include the following:
#include <stdlib.h>
#include <ctime>
Since the seed for random numbers is set using this: srand(time(NULL)), you'll need the ctime library along with stdlib.h, which includes the srand() and rand() function. There is no function in these libraries called 'randomize()'. Hope this helps
- 1
there isn't any function named randomize() in standard library
there is function called rand() in <stdlib.h>