prashantpal84 has asked for the wisdom of the Perl Monks concerning the following question:
why its going in infinite loop??????%hash = (a=>1,b=>2); $count = 0; while(($key,$value) = each %hash) { $count++ if $value==keys(%hash); } print $count;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: hash and while
by jwkrahn (Abbot) on Aug 05, 2010 at 06:12 UTC | |
by Anonymous Monk on Aug 05, 2010 at 07:06 UTC | |
by AnomalousMonk (Archbishop) on Aug 05, 2010 at 12:26 UTC | |
|
Re: hash and while
by Ratazong (Monsignor) on Aug 05, 2010 at 06:20 UTC | |
|
Re: hash and while
by roboticus (Chancellor) on Aug 05, 2010 at 13:07 UTC |