Last active
July 16, 2018 16:45
-
-
Save waleedsamy/d86a11d673a6a478ef5e9ee8f1d71d83 to your computer and use it in GitHub Desktop.
Use AWK to add numbers from two files
This file contains 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 'FNR==NR{a[NR]=$1;next}{ print $0 " + " a[FNR] " = " $0+a[FNR]}' total-time-317.log total-time-330.log |
This file contains 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
3802 | |
3750 | |
13600 | |
3238 | |
19554 | |
20293 | |
19979 | |
13266 | |
10928 |
This file contains 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
4734 | |
4049 | |
12993 | |
3577 | |
17387 | |
21282 | |
18144 | |
12125 | |
12451 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
output: