|
|
| Perl-Sensitive Sunglasses | |
| PerlMonks |
Re^2: Regex to remove databy rjt (Pilgrim) |
| on Nov 06, 2012 at 17:19 UTC ( #1002533=note: print w/ replies, xml ) | Need Help?? |
|
This is good, but the OP did say he wanted to remove the lines from a "large file", but your approach reads the entire file into an in-memory array (@lines) and processes that. Check out my reply below for an example that loads only one line into memory at a time (the -n switch assumes while (<>)).
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||