while (defined(my $line = shift @array))