Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Stepping through a hash while modifiying its content

by Gorgarian (Initiate)
on Dec 28, 2012 at 04:48 UTC ( #1010615=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
      while ( ($key, $value) = each %hash ){
      }
      
    
  2. or download this
      @array = keys %hash;
      foreach $key (@array){
    ...
       # key, value deletions.
      }
      
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1010615]
Approved by muba
Front-paged by Lotus1
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (14)
As of 2014-08-21 20:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (143 votes), past polls