0

Does anyone know if Activeperl uses Windows 'stdlib' for the rand and srand function? I'm using perl 5.16. Thanks in advance for your response.

Deduplicator
  • 44,692
  • 7
  • 66
  • 118
shirha
  • 1
  • 1

1 Answers1

-1
my $s = 4071;
my  $rnd = sub {return (($s = ($s * 214013 + 2531011) % 2 ** 31) >> 16 )};
foreach(0..51){print $rnd->()," "}
print "\n";
srand(4071);
foreach(0..51){print rand()*2**15," "}
print "\n";

Deal_cards_for_FreeCell#Perl

shirha
  • 1
  • 1