How do I use variable string value as a regular expression?

On 4/11/06, Oliver Block <[EMAIL PROTECTED]> wrote:
>
> Am Mittwoch, 12. April 2006 00:38 schrieb Sonika Sachdeva:
> > my $regex="$pattern1 && $pattern2  && $pattern3";
> > print $line if ($line =~ /$regex/);
> >
> > doesn't work...
> Why should it work?
>
> regards,
>
> Oliver
>
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> <http://learn.perl.org/> <http://learn.perl.org/first-response>
>
>
>

Reply via email to