#!/usr/bin/perl use warnings; use strict; my @fh; # will store the filehandles. # Open multiple files. for my $i (1 .. 10) { open $fh[$i], '>', "file-$i" or die $!; } # Write in each. Not sure whether it's simultaneous enough. for my $i (1 .. 10) { print {$fh[$i]} $i; }