for (1 .. 10) { push @records, $_ * $_; } foreach my $record (@records) { print $record, "\n"; }