- or download this
#!/usr/bin/perl
$string = 'test';
...
if ( $_ =~ $string ) { print $_; }
}
close(IN);
- or download this
#!/usr/bin/perl
use strict;
...
}
}
close( $in ); # see perlfunc
- or download this
#!/usr/bin/perl
use strict;
...
# takes filenames on the command line or STDIN if none
print ( ( split )[1] );
}