mirror of https://github.com/cheat/cheat.git
Merge pull request #40 from carlosp420/master
cheat awk: sum integers from a file or stdin
This commit is contained in:
commit
29e9215f82
|
@ -0,0 +1,2 @@
|
|||
# sum integers from a file or stdin, one integer per line:
|
||||
printf '1\n2\n3\n' | awk '{ sum += $1} END {print sum}'
|
Loading…
Reference in New Issue