Reputation:
I am trying add two columns in a text file that are seperated by tabs. I need to use awk to do this. They are two integers that i need to add.
Upvotes: 3
Views: 11732
Reputation: 23866
This should work
awk '{ print $1+$2; }' file.txt
Upvotes: 7