This is what you want...

if ($node =~ /ma.*ny|ny.*ma/)

You didn't specify the order, so I included both.  You might find that you
get a better performance from using what you already are using.  You would
need to check it though.

So to anwer your question, no, '&&' will not work.  Use ".*" to represent
any number of characters instead.

Rob


-----Original Message-----
From: Ravi Malghan [mailto:[EMAIL PROTECTED]
Sent: Tuesday, April 01, 2003 3:20 PM
To: [EMAIL PROTECTED]
Subject: && does not work in =~ /(ma&&ny)/


Hi:
I am using a statement currently as follows
if(($node =~ /ma/) && ($node =~ /ny/))

Using the following statement does not seem to be
giving expected results
if($node =~ /(ma&&ny)/

where as: if(($node =~ /ma/) | ($node =~ /ny/)) 
is same as
if($node =~ /(ma|ny)/)

Thanks
Ravi

__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online, calculators, forms, and more
http://platinum.yahoo.com

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to