my @array = (1,2,3..9,-12); foreach my $variable (@array) { print "$variable is in the list\n"; }