home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
database
/
db3rand.zip
/
TESTRAND.PRG
< prev
next >
Wrap
Text File
|
1989-11-02
|
796b
|
44 lines
* testrand.prg is a dbase program to illustrate use of a
* random number generator in the util.prg file called random.prg
* CALL FUNCTION BY: 'do random with randnum,maxnumber'
* where randnum is the random number passed back and maxnumber is
* the largest possible integer that is possible.
close procedure
set procedure to util.prg
*INITIALIZE MEMORY VARIABLE
randnum = 0
?'FIND RANDOM NUMBERS FROM 0 TO 9999'
do random with randnum,9999
?randnum
do random with randnum,9999
?randnum
?
?'FIND RANDOM NUMBERS FROM 0 TO 99'
do random with randnum,99
?randnum
do random with randnum,99
?randnum
?
?'FIND RANDOM NUMBERS FROM 0 TO 9'
do random with randnum,9
?randnum
do random with randnum,9
?randnum
do random with randnum,9
?randnum