Title: RE: Terrible at my logic

@a = (0..9,A..Z,a..z);

for($I=0;$I<1000;$I++) {

   for($x=0;$x<8;$x++) {

      $index   = rand @a;

      print $a[$index];

   }

   print "\n";

}

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Krishna, Hari
Sent: Tuesday, October 29, 2002 12:48 PM
To: 'FARRINGTON, RYAN'; [EMAIL PROTECTED]
Subject: Random numbers

 

Hi friends,

    I want to generate some 1000 or more passwords for some NT machine.

I should be able to generate an 8 digit alphanumeric random numbers from the list of characters.

 

Say I have 3 strings...

First string : 0 - 9 numbers

Second string : A - Z characters

Third string: a - z characters.

 

Now I should be able to generate strings like:

 

"abCd16Sz"

"U8Yb90vc"

"Nt7gO0PL"

 

something like that.

 

Is there a way to generate such kind of random numbers 8 characters long???

 

I saw in a bok that there is a module in PERL

MATH::TrulyRandom

 

but I am not sure if it helps. I will keep trying.

 

 

any inputs appreciated.

 

Hope I can get some help.

 

 

Thanks and Regards,

Hari.

Reply via email to