SilverScreen Solid Modeler

rand

rand

Previous topic Next topic  

rand

Previous topic Next topic JavaScript is required for the print function  

StandardCLibrary

 

int rand( void )

 

 

 

 

 




Synopsis

#include "stdlib.h"

 

The rand function returns a pseudo-random number.

 

 

Parameters

none

 

 

Return Value

rand returns a pseudo-random number. The number is in the range from 0 to RAND_MAX (defined in stdlib.h).

 

 

Comments

srand may be used to "seed" the pseudo-random number generator that generates values returned by rand; if rand is called before srand, the seed used will be 1.

 

 

See Also

srand