That idea of "faster" is true in Python's equivalent, but I'm not at all sure about that in Perl.
In Perl, the foreach loop should run at about the same speed.
In reply to Re^2: iterating through array and saving matches to new array
by Marshall
in thread iterating through array and saving matches to new array
by jazzfan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |