Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: WHAT IS WRONG TO PASS PARAMETER TO THE ARRAY?

by n3toy (Hermit)
on Aug 05, 2009 at 11:54 UTC ( [id://786071]=note: print w/replies, xml ) Need Help??


in reply to WHAT IS WRONG TO PASS PARAMETER TO THE ARRAY?

In line 4 you are assigning an array of hashes to @partofcookie, then in line 5 you are assigning a variable to @partofcookie, overwriting your original array of hashes.

(Also, no need to include the line numbers, see Writeup Formatting Tips)

  • Comment on Re: WHAT IS WRONG TO PASS PARAMETER TO THE ARRAY?

Replies are listed 'Best First'.
Re^2: WHAT IS WRONG TO PASS PARAMETER TO THE ARRAY?
by Bloodnok (Vicar) on Aug 05, 2009 at 12:09 UTC
    I disagree over the inclusion of line numbers esp. when large code samples are involved - IMO, it makes for far more readable discussion without the need for ad-hoc replication of bits of the OP code.

    BTW, Writeup Formatting Tips doesn't, AFAICT, mention line numbering ... or the exclusion/removal thereof.

    A user level that continues to overstate my experience :-))

      I was just going to edit my node and add that, Writeup Formatting Tips does not talk about line number (I just looked), but you caught my error first. Good catch! The OP did post just fine.

        so they really should mention that, having to delete the line numbers when click "download code" is so bad as don't put code tags at all.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (4)
As of 2024-04-23 23:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found