Re: Need help w/ reqexp, capture and substitue

2006-10-29 Thread Shawn Milochik
On Oct 29, 2006, at 7:56 PM, Dennis G. Wicks wrote: Shawn Milochik wrote: This seems to work for me: #!/usr/bin/perl -w use strict; while () { chomp; print "Original: $_\n"; $_ =~ s/^([EMAIL PROTECTED])(@.+&\d+&)([&]{5})/$1$2$1$3/;

Re: Need help w/ reqexp, capture and substitue

2006-10-29 Thread Shawn Milochik
This seems to work for me: #!/usr/bin/perl -w use strict; while () { chomp; print "Original: $_\n"; $_ =~ s/^([EMAIL PROTECTED])(@.+&\d+&)([&]{5})/$1$2$1$3/; print "Modified: $_\n"; } Hope it helps. Shawn -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additi

To shebang or not to, and script feedback.

2006-10-21 Thread Shawn Milochik
Hello all. I've been spending too much money lately on Amazon buying Perl books. Recently, I've been playing with scripts downloaded from the Web site of a book I'm going through. For some reason, some of the .pl files have a shebang, and others do not. 1. What's the difference, other than