in reply to Re: Regex stored in a scalar
in thread Regex stored in a scalar
use strict; use warnings; my $regex=<STDIN>; #Entering s/\),\(/\)\n\(/gi chomp $regex; open (INPUTFILE, "< $filein"); while (<INPUTFILE>) { my $line=$_; #$line =~ $regex; eval "\$line =~ $regex"; };
|
|---|