http://www.perlmonks.org?node_id=1013860


in reply to How to check whether my array contains element x

See the function "any" in List::MoreUtils. It does exactly what you ask.
Bill
  • Comment on Re: How to check whether my array contains element x