Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR C

how to genrate a random number in C

#include <time.h>
#include <stdlib.h>

srand(time(NULL));   // Initialization, should only be called once.
int r = rand();      // Returns a pseudo-random integer between 0 and RAND_MAX.
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #genrate #random #number #C
ADD COMMENT
Topic
Name
4+3 =