for ( my $i = 0; $i <= $#{ $arrayref }; $i++ ) { print "$arrayref->[$i] \n"; }