in reply to capturing separately
As far as I could deduce from your description, the following should do:
# values to be used in an array ... my @array= map /\bkingdom\|([^|]+)\|/g, <>; # and stored in a hash as individual keys my %hash; $hash{$_}++ for @array; # show: print map "kingdom $_ was $hash{$_} x <br />\n", keys %hash;
Regards
mwa
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: capturing separately
by ada (Novice) on Dec 10, 2007 at 16:23 UTC |