LPM: RE: join

Rich Bowen rbowen at rcbowen.com
Sun Apr 2 20:47:29 CDT 2000


repett0 at sac.uky.edu wrote:
> 
...
> for($i=0; $i<10; $i++)
>   $foo[$i] = int(rand(10));

By the way, I couldn't resist. A more "Perlish" way to do this would be:

$foo[$_] = int(rand(10)) for (1..10);

:-)

Rich
-- 
http://www.ApacheUnleashed.com/
Lexington Perl Mongers - http://lexington.pm.org/
PGP Key - http://www.rcbowen.com/pgp.txt



More information about the Lexington-pm mailing list