Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Dereferencing of an arrayref within a hashref

by Not_a_Number (Prior)
on Feb 17, 2015 at 09:20 UTC ( [id://1116953]=note: print w/replies, xml ) Need Help??


in reply to Dereferencing of an arrayref within a hashref

my @a1 = qq/one two three four five/;

This probably isn't doing what you think it's doing: it creates a single string* 'one two three four five'.

To create a five-element array, use qw instead of qq.

* Update: and asssigns it to $a1[0].

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-04-16 15:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found