use strict; use warnings; my ($a); my @b=(2,4,6,7); foreach $a (@b) { print $a}