How can I check if a Perl array contains a particular value? - Stack Overflow
Best general purpose - Especially short arrays (1000 items or less) and coders that are unsure of what optimizations best suit their needs. # $value can be any regex. be safe if ( grep( /^$value$/, @array ) ) { print "found it"; } It has been mentioned th...