Mercurial > cpython-lru_cache-weakref
view Doc/librand.tex @ 5817:48b94de85bf3 legacy-trunk
Extensive changes by AMK.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Thu, 17 Jul 1997 16:29:42 +0000 |
| parents | 72986b716824 |
| children | 3468ea8645ca |
line wrap: on
line source
\section{Standard Module \sectcode{rand}} \stmodindex{rand} The \code{rand} module simulates the C library's \code{rand()} interface, though the results aren't necessarily compatible with any given library's implementation. While still supported for compatibility, the \code{rand} module is now considered obsolete; if possible, use the \code{whrandom} module instead. \begin{funcdesc}{choice}{seq} Returns a random element from the sequence \var{seq}. \end{funcdesc} \begin{funcdesc}{rand}{} Return a random integer between 0 and 32767, inclusive. \end{funcdesc} \begin{funcdesc}{srand}{seed} Set a starting seed value for the random number generator; \var{seed} can be an arbitrary integer. \end{funcdesc}
