In your loop over the lines of each file, you say
while( my $line = <FILE> ) { chomp($line); if( $line =~ / SIL$/ ) { print $line, "\n"; last; } }
UPDATE: Removed ~ in assignment to $line, thanks to Loops!
In reply to Re: removing lines that are in the end of a file
by hdb
in thread removing lines that are in the end of a file
by bhargavkanakiya
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |