XP is just a number | |
PerlMonks |
Re: Re: using strict and functionsby rob_au (Abbot) |
on Jan 18, 2002 at 04:27 UTC ( [id://139683]=note: print w/replies, xml ) | Need Help?? |
One point here ... Your use of the loop construct of for (;;) is very C-stylish and possibly not the best way to perform a simple forward iteration as your suggest. A more straight-forward way would be to make use of the range operator. eg.
If you require lexical scoping of the iteration variable, you can do so with the variable name and the my keyword. This syntax and the range operator are discussed in perlsyn and perlop respectively.
perl -e 's&&rob@cowsnet.com.au&&&split/[@.]/&&s&.com.&_&&&print'
In Section
Seekers of Perl Wisdom
|
|