Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: Simple question about foreach and my.by THRAK (Monk) |
on Mar 27, 2001 at 18:35 UTC ( [id://67497]=note: print w/replies, xml ) | Need Help?? |
In some case I find it easiest to not even use a variable, but rely on your friend: $_
There are many times when this is useful. This might not be the best example but it is one possible use. In this case to do a substitution in each array entry. I think a bigger point would be that you have found your way to "use strict". A definate thing you should always do. THRAK
In Section
Seekers of Perl Wisdom
|
|