Last active
August 29, 2015 14:06
-
-
Save trilitheus/0a3083d486d0c56492f0 to your computer and use it in GitHub Desktop.
Awk sum columns
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
awk '{ sum+=$1} END {print sum}' FILENAME | |
awk '{ sum+=$5 } {sum2+=$6 } END {print sum, sum2}' FILENAME |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment