in reply to Yet Another Stupid CGI Question
my @array = ( 4,5,3,4,5); print function(),"\n"; sub function { my $rv; foreach my $item (@array) { $rv .= $item . "\t"; } return $rv; }
and put the foreach loop in a sub (or anon. sub). I know the example above looks silly but i had to work the foreach in to illustrate my point. HTH
|
---|