gasho has asked for the wisdom of the Perl Monks concerning the following question:
Thanks in advance Gashosub getInfoFromLongLine { #Openning file for reading open(IFH,"$InputFile") || die "Can't open file: $InputFile\n"; while($line=<IFH>) { if ($line=~/.*START(.*?)END/) { push(@Result,$1); } if ($line=~/.*?START(.*?)END/) { push(@Result,$1); } } return @Result; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to deal with long line
by GrandFather (Saint) on Sep 27, 2005 at 20:50 UTC | |
by gasho (Beadle) on Sep 28, 2005 at 13:09 UTC | |
|
Re: How to deal with long line
by philcrow (Priest) on Sep 27, 2005 at 21:04 UTC | |
|
Re: How to deal with long line
by chester (Hermit) on Sep 27, 2005 at 20:47 UTC |