Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^4: How to create a new array with the same name as an existing one in a loop? (updated)

by AnomalousMonk (Archbishop)
on Aug 15, 2021 at 18:32 UTC ( [id://11135863]=note: print w/replies, xml ) Need Help??


in reply to Re^3: How to create a new array with the same name as an existing one in a loop?
in thread How to create a new array with the same name as an existing one in a loop?

i want to be able to copy everything.

Why? Why not just create a new array reference each time through the loop? Again, I don't think we have a good idea of your true requirement. Please see Short, Self-Contained, Correct Example.

Update: In any event, searching with "deep copy" on MetaCPAN brings up Clone (update: and Clone::PP), about which I know nothing.


Give a man a fish:  <%-{-{-{-<

  • Comment on Re^4: How to create a new array with the same name as an existing one in a loop? (updated)
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11135863]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (6)
As of 2024-04-20 00:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found