##
my $found_flag = 0;
foreach my $item ( @list ) {
if( $item eq $find ) {
$found_flag = 1;
last;
}
}
if( $found_flag ) {
print "Found $find.\n";
}
##
##
use List::Util;
my @list = qw/ this that other /;
my $find = "that";
if( first { $_ eq $find } @list ) {
print "I found it!\n";
}