$x='y';
if($x=~/[xyz]/)     # checks for match to any character in set
{
        print 'yes';
}
else
{
        print 'no';
}

On Monday, March 4, 2002, at 11:33  AM, Dennis G. Wicks wrote:

> Greetings;
>
> Is there some perl shorthand that will make it easier to say
>
>       if ( $x eq 'X' || $x eq 'Y' || $x eq 'Z' )
>
> TIA,
> Dennis
>
> --
> 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