summaryrefslogtreecommitdiff
path: root/src/stdlib/rand.c
blob: 459332ce396790757292869312b3a0f19961fda9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include <stdlib.h>
#include "nonstd/internal.h"
#include "_rand.h"

/** get a pseudo-random number **/
int rand(void)
{
	return _rand(*(unsigned*)__libc(RAND));
}

/***
computes a pseudo-random number in the range [0,CONSTANT(RAND_MAX)].
***/

/*
RETURN_SUCCESS(a pseudo-random integer)
STDC(1)
*/