#!/usr/bin/perl -- use strict; use warnings; use File::Slurp; my @junk = ("junk") x 15; for my $f ( @junk ){ my( $what, $junk ) = split /whatever/, scalar read_file( $f ); }