#!/usr/bin/perl use strict; use warnings; $[ = 3; my @array = qw(1 2 3 4); for my $i($[ .. $#array ){ print $array[$i],"\n"; }