hello,
i was given an assigment to write a program that asks for the name of a roster file that has students names in it. Then the program promts for eacht students grade and with those grades does some calculations. At the end a table is outputted with the name of the student and the calculations. the program is include an array. My question is, how do i know how many students are in the file? is there some kind of method that counts the lines of the text file?
this is my first few lines of the program
String DataFileName="";
DataFileName=keyb.askString("What is the name of your roster?");
File inFile=new File(DataFileName);
that last line, does that read the file or just creates a new File instance? and should my array in my program consist of the students names or there grades?