## ... my @file_data; sub fetcher { ## ... while ... for ... { ## ... push @file_data, $i; $ct++; } } ## print here...