in reply to find the element position of $scalar
my $i = 0; foreach my $scalar (@array) { print $scalar, " is at position ", $i++, "\n"; } [download]
-- John.