my $found = 0; my @array_I_just_created_here = (a .. z); $found |= ("c" eq $array_I_just_created_here[$_]) foreach (0..$#array_I_just_created_here); print "yes, c is a letter that would exist within that array you just created there.$/" if $found;