http://www.perlmonks.org?node_id=997299


in reply to Reoccuring message

Always:

use strict; use warnings;

Also, use lexically-scoped variables, e.g.:

my @array ... my $i ... my $element ...

And I think you may have meant the following:

$i < 10 $array[$i]

Hope this helps!