debian man page for ns_rand

Query: ns_rand

OS: debian

Section: 3aolserv

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

ns_rand(3aolserver)					    AOLserver Built-In Commands 				       ns_rand(3aolserver)

__________________________________________________________________________________________________________________________________________________

NAME
ns_rand - commands
SYNOPSIS
ns_rand ?max? _________________________________________________________________
DESCRIPTION
ns_rand generates a cryptographically-secure random number. If max is not specified, the random number is a floating-point value n such that 0.0 <= n < 1.0. If max is specified, it must be a positive integer between 0 and 2147483647. The return value is an integer value such that 0 <= n <= (max - 1). Internally ns_rand is implemented with the drand48(3) and lrand48(3) standard library functions. An internal random seed is generated the first time ns_rand is called after the server starts.
EXAMPLES
nscp> ns_rand 0.39938485692 nscp> ns_rand 10 7
SEE ALSO
nsd(1), info(n), drand48(3), lrand48(3)
KEYWORDS
AOLserver 4.0 ns_rand(3aolserver)
Related Man Pages
ns_log(3aolserv) - debian
ns_logctl(3aolserv) - debian
ns_rand(3aolserv) - debian
_rand48(3) - freebsd
erand48(3) - freebsd
Similar Topics in the Unix Linux Community
Maximum File Size
How to read max of 10 file at a time?
Calc max of a column
I want to test max process on my system
Process, where each process generates a random integer