I have an assignment where I need to read values from an external text file and do some computations with them. The file is a control number file, with 22 lines and three numbers on each line. I have no problem setting up the file pointers, reading the file and storing numbers from the file in variables. My issue is that I need to take the sum of all the third numbers from each line. Searching the internet gave me lots of examples using fgets() and sscanf() etc. We haven't learned those in class yet, so I'm not using those. We've discussed loops (for, while etc.) and if statements. I'm just stumped as to how I might get those numbers and add them up to be used in a calculation. The formula is something like X(Y1+Y2+Y3.....) with the Y values being that third number from each line. It seems that whenever I uses the fscanf function, which is the only file scanning function I know, it reads the first line only.