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


in reply to in function?

While ferrency's answer is a better way to go about it overall, the most direct answer to your question would be
if(grep {$_ eq 'blah'} @myarray) { # stuff }