mikew@wyse.wyse.com (Mike Wexler) (01/05/89)
Submitted-by: moraes@csri.toronto.edu (Mark Moraes) Posting-number: Volume 2, Issue 73 Archive-name: life/part02 #! /bin/sh # This is a shell archive. Remove anything before this line, then unpack # it by saving it into a file and typing "sh file". To overwrite existing # files, type "sh file -c". You can also feed this as standard input via # unshar, or by typing "sh <file", e.g.. If this archive is complete, you # will see the following message at the end: # "End of archive 2 (of 2)." # Contents: random.h # Wrapped by mikew@wyse on Wed Jan 4 09:57:37 1989 PATH=/bin:/usr/bin:/usr/ucb ; export PATH if test -f 'random.h' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'random.h'\" else echo shar: Extracting \"'random.h'\" \(244 characters\) sed "s/^X//" >'random.h' <<'END_OF_FILE' X#ifdef HAVE_RANDOM Xextern long random(); X#define rnd(x) (random() % (long) (x)) X#define seedrnd(x) (srandom(x)) X#else /* ! HAVE_RANDOM */ Xextern int rand(); X#define rnd(x) (rand() % (x)) X#define seedrnd(x) (srand(x)) X#endif /* HAVE_RANDOM */ END_OF_FILE if test 244 -ne `wc -c <'random.h'`; then echo shar: \"'random.h'\" unpacked with wrong size! fi # end of 'random.h' fi echo shar: End of archive 2 \(of 2\). cp /dev/null ark2isdone MISSING="" for I in 1 2 ; do if test ! -f ark${I}isdone ; then MISSING="${MISSING} ${I}" fi done if test "${MISSING}" = "" ; then echo You have unpacked both archives. rm -f ark[1-9]isdone else echo You still need to unpack the following archives: echo " " ${MISSING} fi ## End of shell archive. exit 0 -- Mike Wexler(wyse!mikew) Phone: (408)433-1000 x1330 Moderator of comp.sources.x