my $element = 'Whatever you are searching for' ; if (grep {$_ eq $element} @TheArray) { print "Element '$element' found!\n" ; }
In reply to Re: How to find out if X is an element in an array?
by Anonymous Monk
in thread How to find out if X is an element in an array?
by juahonen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |