use strict; my @a=(1..100); for my $i (0..@a-1) { print $a[i]; } #### use strict; my $a=[1..100]; for my $i (0..$a-1) { print $a->[i]; }