MaroonBalloon has asked for the wisdom of the Perl Monks concerning the following question:
Each hash value is a long sequence of about 300 characters. If I search for a common letter, I will get $contains to equal to number of hash sequences instead of the true number of characters in the collection of values. Thanks!while (my ($key,$value) = each(%no)) { if ($value =~/$search/gi) { $contains++; } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Simple (probably)
by ikegami (Patriarch) on Dec 13, 2009 at 04:49 UTC | |
by MaroonBalloon (Acolyte) on Dec 13, 2009 at 05:21 UTC | |
by ikegami (Patriarch) on Dec 13, 2009 at 05:37 UTC | |
|
Re: Simple (probably)
by FalseVinylShrub (Chaplain) on Dec 13, 2009 at 04:44 UTC | |
by MaroonBalloon (Acolyte) on Dec 13, 2009 at 05:18 UTC |