in reply to Random number
Here's how I generate random strings. You can just have 0 .. 9 in @Chars if you want an integert. And change 1 .. 30 to loop however many times you like - this example creates a random string that is 30 chars long.my @Chars = ( "A" .. "Z", "a" .. "z", 0 .. 9); my $RandString = join("", @Chars[ map { rand @Chars } ( 1 .. 30 ) ]);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
RE: RE: Random number
by greenhorn (Sexton) on Jul 10, 2000 at 11:53 UTC | |
by chromatic (Archbishop) on Jul 10, 2000 at 21:45 UTC |