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

Re^11: Computing results through Arrays

by robby_dobby (Hermit)
on Jun 24, 2015 at 10:02 UTC ( [id://1131780]=note: print w/replies, xml ) Need Help??


in reply to Re^10: Computing results through Arrays
in thread Computing results through Arrays

Hello yasser8@gmail.com,

The problem here is in this line:

print fnd_max %m

You see, the fnd_max sub requires a hashref, while you're passing a full hash into it. Also, why are you using prototypes for your subroutine? Unless you're using v5.20, where subroutine signatures were introduced, don't use them. To correct your problem, change the %m to \%m - make it clear that it's a sub call, print fnd_max(\%m). Not really important, this is just my convention.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-04-25 14:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found