Beefy Boxes and Bandwidth Generously Provided by pair Networks RobOMonk
Perl: the Markov chain saw
 
PerlMonks  

Re^2: difference between @, $

by johngg (Abbot)
on Dec 07, 2011 at 18:12 UTC ( #942300=note: print w/ replies, xml ) Need Help??


in reply to Re: difference between @, $
in thread difference between @, $

It can also be useful to name the variables using Dump() or Dumpxs() (see Data::Dumper) to avoid confusion.

knoppix@Microknoppix:~$ perl -MData::Dumper -E ' > @arr1 = ( 1 .. 4 ); > @arr2 = [ 1 .. 4 ]; > $arr3 = [ 1 .. 4 ]; > print Data::Dumper->Dumpxs( > [ \ @arr1, \ @arr2, $arr3 ], > [ qw{ *arr1 *arr2 arr3 } ], > );' @arr1 = ( 1, 2, 3, 4 ); @arr2 = ( [ 1, 2, 3, 4 ] ); $arr3 = [ 1, 2, 3, 4 ]; knoppix@Microknoppix:~$

I hope this is of interest.

Cheers,

JohnGG


Comment on Re^2: difference between @, $
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2014-04-20 18:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (486 votes), past polls