That would work fine, or you could change both to the same case for the duration of the comparison:
if ( "\U$x" eq "\U$y" ) Rob ----- Original Message ----- From: "Dylan Boudreau" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, December 03, 2002 1:30 PM Subject: RE: Case Insensitive > I could be wrong here as I am still pretty new to perl but couldn't you > just do it like this > > if ($x =~ /$y/i) > > Dylan > > -----Original Message----- > From: SATAR VAFAPOOR [mailto:[EMAIL PROTECTED]] > Sent: December 3, 2002 9:27 AM > To: [EMAIL PROTECTED] > Subject: Case Insensitive > > > > Hello all, > > I want to make comaprisons in an if statement without caring about upper > or lower case eg $x='T'; $y='t' if($x eq $y). can the i that is used in > regex be used here or is there another way. Thanks > > Sattar > -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]