Vote count:
0
How can I read a column and add each entry from a file using .sh?
Example file:
10000:max:100:1,2:3,4
10001:jill:50:7,8:3,2
10002:fred:300:5,6:7,8
How to use IFS=':' to read that file with a .sh file line by line and add the third part so that it would output the addition e.g. 450
$ ./myProgram myFile.txt
450
Cheers,
Joshua
asked 16 secs ago
How to separate and add numbers from a file with .sh
Aucun commentaire:
Enregistrer un commentaire