Your skill will accomplish what the force of many cannot |
|
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
It helps to know that is equivalent to and that foreach (LIST) flattens the list it gets. (Well, there are some special cases like foreach (ARRAY) and foreach (RANGE) that are more efficient.) See the documentation on readline to find out how it behaves differently when used in list context. In Perl 6, this will not be much of a problem, since it will have "lazy lists". A normal for (LIST) will do what you mean, in an efficient way. Juerd # { site => 'juerd.nl', plp_site => 'plp.juerd.nl', do_not_use => 'spamtrap' } In reply to Re: file processing, while and foreach: a n00b experience
by Juerd
|
|