Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: array confusion

by BUU (Prior)
on Aug 21, 2003 at 06:17 UTC ( [id://285366]=note: print w/replies, xml ) Need Help??


in reply to array confusion

when you do  for my $foo () $foo is aliased to the var. But when you assigned the scalars to a list they were copied so when you did @arr = ($foo,$baz,$bar); for(@arr){s/stuff/cling/;} you were actually affecting $arr[0],$arr[1],$arr[2] and so on.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (8)
As of 2024-04-16 08:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found