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

Re: The Drivel is in the Details

by blazar (Canon)
on May 29, 2007 at 23:01 UTC ( #618081=note: print w/replies, xml ) Need Help??

in reply to The Drivel is in the Details

Why is the -> necessary in $source->{$node}

Because $source is a (hash) reference and it needs to be dereferenced.

and why the %$ and @$ symbols instead of just % and @?

Because the symbols are still simply % and @, but now you're using them to dereference something that is held in a scalar, which is prefixed by the $ sigil: this is another method for dereferencing, and in its full blown form it should be:

%{ $hashref }

But in this simple case the curlies can be omitted. In more complex contructs, they cannot.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://618081]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2017-09-22 05:55 GMT
Find Nodes?
    Voting Booth?
    During the recent solar eclipse, I:

    Results (257 votes). Check out past polls.