Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re^3: print a hash ref

by nemesdani (Friar)
on Jul 09, 2013 at 14:14 UTC ( #1043324=note: print w/replies, xml ) Need Help??

in reply to Re^2: print a hash ref
in thread print a hash ref

Not a nice way, but if it's only for printing, treat it like a number, e.g. add 0 to it and print the result.

I'm too lazy to be proud of being impatient.

Replies are listed 'Best First'.
Re^4: print a hash ref
by teamassociated (Sexton) on Jul 09, 2013 at 14:39 UTC
    well its a lot of prints, 114 to be exact.

      You should not have 114 prints.

      Try replacing them with a loop around a single print:

      print "$key : $hash{key}\n" for (keys %hash)
      So? You have to modify print only once.

      I'm too lazy to be proud of being impatient.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2017-11-24 06:35 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (345 votes). Check out past polls.