Howdy:

I have this bit of code (below) and I'm wondering 
if there is a quicker way to remove 
some odd-ball characters from very
large text files (large would be about the
200M or so).

[snip code]

#!/usr/bin/perl

#$_ =~ s/\cM\n/\n/g;

while (<>) {
   $_ =~ s/(\cM\n|\\|\~|\!|\@|\#|\$|\%|\^|\&|\*|\(|\))/\n/g;
   print $_;
}

[/snip code]

I want to add some variable to pass (and rename INPUT file)
but before I do, I'd like to know if doing something like open()
would be any faster than this. 

Thanks!

-X

Reply via email to