RE: What is the and operator in perl

2003-01-30 Thread Kipp, James
&& or and both work perldoc perlop > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Thursday, January 30, 2003 8:55 AM > To: [EMAIL PROTECTED] > Subject: What is the and operator in perl > > > If I want to do something like > > if ($a=$b) and ($

Re: What is the and operator in perl

2003-01-30 Thread Jenda Krynicky
From: [EMAIL PROTECTED] > If I want to do something like > > if ($a=$b) and ($d=$e) > Is it possible? > > because & is for bitwise AND operation. if ($a==$b and $d==$e) or if (($a==$b) && ($d==$e)) Please note that I'm using ==. == is numerical

RE: What is the and operator in perl

2003-01-30 Thread Nigel Peck - MIS Web Design
you can use "and" or "&&". if (($a==$b) && ($d==$e)) { # code here } and has a lower precedence than &&. For or there's "or" or "||" HTH Nigel MIS Web Design http://www.miswebdesign.com/ > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: 30 Janu