I hope this helps!#!/usr/bin/perl -w print "\nWhat file would you like to open: "; chomp ($file = <STDIN>); print "\nAttempting to open $file\n"; open(FILE, "$file") || die "Unable to open file: $file\n"; while(<FILE>) { $text =~ $_; if($text eq "go"){ $text =~ s/^go/\//g; $count++; } } print "There are $count lines in this file\n"; close FILE;
In reply to Re: Matching Question
by Anonymous Monk
in thread Matching Question
by curtisb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |