http://qs321.pair.com?node_id=665219


in reply to Need help testing to see if a variable is one value or the other

if ($var eq "yes" or $var eq "no"){ ... } will do the job.

The way you write it is planned for Perl 6:

if $var eq any <yes no> { ... }

Replies are listed 'Best First'.
Re^2: Need help testing to see if a variable is one value or the other
by paulehr (Sexton) on Jan 30, 2008 at 21:32 UTC

    thanks guys!

    I knew this was probably going to be something easy. I do not know why I was having a hard time with it.