Generates a pseudo-random number.
This function generates a pseudo-random number in the range betwenn 0 to FNET_RAND_MAX