On Fri, Apr 25, 2014 at 12:18 PM, Harry Putnam <rea...@newsguy.com> wrote:
> About just using 'shift': How I happened to be using that weird > looking notation at all was because I thought it was a way to avoid > the extra step of compiling the rgx in qr// after shifting. My advice to you on this point would be that when you're trying to do two things, it's perfectly okay to use two lines of code to do it. (It's even okay sometimes when you're only trying to do one thing!) Perl doesn't charge you by the lines of code you use, so doing this: my $re = shift; $re = qr/$re/; is just fine. chrs, john. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/