Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- my $in_file = 'cn.txt';
- open my $in_fh, '<', $in_file or die "Could not open file $in_file: $!
- +";
- my $out_file = 'liboutput.txt';
- open my $out_fh, '>', $out_file or die "Could not open file $out_file:
- + $!";
- while ( my $line = <$in_fh> ) {
- print {$out_fh} $line if $line =~ /\|LIB\|/;
- }
- close $in_fh or die "Could not close file $in_file: $!";
- close $out_fh or die "Could not close file $out_file: $!";
Advertisement
Add Comment
Please, Sign In to add comment