G'day tty1x,
Changing my $count; to my $count = 0; should fix your "uninitialised value" problems.
[Aside: you can write ++$count; instead of $count += 1;]
-- Ken
In reply to Re: counter for each regex match.
by kcott
in thread counter for each regex match.
by tty1x
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |