Skip to content

Instantly share code, notes, and snippets.

@spara
Created January 18, 2012 01:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spara/1630290 to your computer and use it in GitHub Desktop.
Save spara/1630290 to your computer and use it in GitHub Desktop.
add a list of numbers in a file
awk '{total+=$0}END{print total}' file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment