Put randomize before of repeat
Lv ha scritto:
> Randomize seems to be 1 second dependent on the system clock.
> I cannot remember if this used to be the same in Borland Delphi/Pascal
> The example below shows a 1 second tick sensitivity to random number
> creation.
>
> Am I missing something?
>
>
> uses unix,crt;
> VAR
> dummystring,filename : String;
> randomnumber : Int64;
> hellfreezesover : Boolean;
>
>
>
> BEGIN
> hellfreezesover:=False;
> Repeat
> Randomize;
> randomnumber:=Random(9999999999999999999);
> writeln('randomnumber=',randomnumber);
> Until (hellfreezesover or keypressed);
> END.
>
> _______________________________________________
> Lazarus mailing list
> [email protected]
> http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>
_______________________________________________
Lazarus mailing list
[email protected]
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus