for $val (@variables) { my %temp; # work with %temp here; push @array, \%temp; }