my $ax = $#$allmatch; print "ax = [$ax]\n"; if ($nr > $ax) {