Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: Array value changing for some reason

by Silt (Novice)
on Dec 31, 2018 at 23:23 UTC ( [id://1227851]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub reverseArray {
        for(my $i=0;$i<scalar(@_);$i++){
            @{$_[$i]} = reverse @{$_[$i]};
        }
    }
    
  2. or download this
    sub reverseArray {
        my @arr = @_;
    ...
            $arr[$i] = [reverse @{$arr[$i]}];
        }
    }
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (4)
As of 2024-03-29 08:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found