unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (SunOS-4.1.3)
Page:
Section:
Apropos / Subsearch:
optional field

RANDOM(6)                        Games Manual                        RANDOM(6)



NAME
       random - select lines randomly from a file

SYNOPSIS
       /usr/games/random [ -er ] [ divisor ]

DESCRIPTION
       random  acts  as a text filter, randomly selecting lines from its stan-
       dard input to write to the standard output.   The  probability  that  a
       given  line  is selected is normally 1/2; if a divisor is specified, it
       is treated as a floating-point number, and the probability is 1/divisor
       instead.

OPTIONS
       -e     Don't  read  the standard input or write to the standard output.
              Instead, exit with a random exit status  between  0  and  1,  or
              between 0 and divisor-1 if divisor is specified.

       -r     Don't  buffer the output.  If -r is not used, output is buffered
              in blocks, or line-buffered if the standard output is  a  termi-
              nal.



                               16 February 1988                      RANDOM(6)