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

Re^2: Efficient way to sum columns in a file

by Anonymous Monk
on Apr 13, 2005 at 13:48 UTC ( #447380=note: print w/ replies, xml ) Need Help??


in reply to Re: Efficient way to sum columns in a file
in thread Efficient way to sum columns in a file

I don't think the '$total += $sub += $F6;' part is doing what you expect it to... Actually, it doesn't add $F6 to both $total and $sub, but rather add it to $sub and then add $sub to $total, which generates a wrong total.


Comment on Re^2: Efficient way to sum columns in a file
Re^3: Efficient way to sum columns in a file
by tlm (Prior) on Apr 13, 2005 at 14:04 UTC

    The totals was obviously wrong; that should have alerted me to the error. Thank you very much!

    the lowliest monk

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (12)
As of 2014-07-30 11:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (230 votes), past polls