Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: $RANDOM ?



Atom Smasher wrote:
> from the man page:
>    The values of RANDOM form an intentionally-repeatable pseudo-random 
> sequence; subshells that reference RANDOM will result in identical 
> pseudo-random values unless the value of RANDOM is referenced or seeded in 
> the parent shell in between subshell invocations.
> 
> i'm curious about the "intentionally-repeatable" sequence. where would i 
> find out more?

It's the call rand() provided by the library and specified by C and
POSIX: http://www.opengroup.org/onlinepubs/009695399/functions/rand.html

-- 
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/



Messages sorted by: Reverse Date, Date, Thread, Author