I'm trying to read from a text file. The format of the text file is
1999 78686
2000 78999
2001 80003
............... .....
............... .....
............... ....
2002 45489 (so forth).
I want to be able to count how many rows are there and also add all the values in the second column.
I want to know how do I go about storing the values once i read the file? should I just increment each line or use Arrays?
1999 78686
2000 78999
2001 80003
............... .....
............... .....
............... ....
2002 45489 (so forth).
I want to be able to count how many rows are there and also add all the values in the second column.
I want to know how do I go about storing the values once i read the file? should I just increment each line or use Arrays?
Comment