Hi the list, Hahem! I asked few days ago about a possibly built-in function giving random or pseudo-random numbers... And received no answer. Why it is so? Is it a trivial FAQ? I checked in GPC info and there is nothing for random but this: * GPC notes:: Random notes about GPC. And for rand, there is nothing but OPErand :) So if it is a FAQ it is well hid. It is by no means a tricky or complicated question, may be it is taboo? Dunno... Don't understand! So heretically I ask again if GPC is providing such a function. Cheers. F.P.L
According to FPL:
Hahem! I asked few days ago about a possibly built-in function giving random or pseudo-random numbers... And received no answer.
I do not remember to have received your question, so I guess it got lost somehow before it reached the list.
[...] I checked in GPC info and there is nothing for random but this: * GPC notes:: Random notes about GPC.
:-))) Try the following: Function Rand: Integer; C; Procedure SRand ( Seed: Cardinal ); C; Placing the above in the declaration part of your program will make use of the random generator in the system's C library. See also ftp://agnes.dida.physik.uni-essen.de/gnu-pascal/contrib/rand.pas for a Borland-compatible random number generator. Hose this helps, Peter -- Peter Gerwinski, Essen, Germany, free physicist and programmer Maintainer GNU Pascal - http://home.pages.de/~GNU-Pascal/ - 1 Oct 1997 PGP key fingerprint: AC 6C 94 45 BE 28 A4 96 0E CC E9 12 47 25 82 75 Fight the SPAM! - http://maps.vix.com/
participants (2)
-
FPL -
Peter Gerwinski