zulqernain has asked for the wisdom of the Perl Monks concerning the following question:
when i put it in hash@array=("abc","def","abc","klm","abc","rbc","Kjm","rbc","abc");
it put the unique keys in hash with value 1 each . i dont know what i should write instaed of 1 so that it save the count as value corrsponding to each keyfor $i (@array) { $hash{$i}=1; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: hash and array
by Tanktalus (Canon) on May 22, 2005 at 14:59 UTC | |
by zulqernain (Novice) on May 22, 2005 at 15:07 UTC | |
|
Re: hash and array
by ivancho (Hermit) on May 22, 2005 at 15:15 UTC | |
by japhy (Canon) on May 22, 2005 at 17:18 UTC | |
by Zaxo (Archbishop) on May 22, 2005 at 20:05 UTC | |
by mrborisguy (Hermit) on May 22, 2005 at 20:12 UTC | |
by ihb (Deacon) on May 23, 2005 at 00:02 UTC | |
| |
by Anonymous Monk on May 23, 2005 at 07:07 UTC |