my @five_only = @A[0..4]; print @five_only #### my @values = split(',', @A); foreach my $val (@values) { d = d + 1); }