I am writing a program in Java. I need to read a file then store the data in an array. Since I need to declare the size of the array so I need to know how many records are in the file. Is there a quick way to find out the number of records in a file without reading through it? If I know the number of records then I can declare the array then read the file and store the data (meaning to read the file once).
2007-03-09
18:43:18
·
3 answers
·
asked by
Sea_turtle
2
in
Computers & Internet
➔ Programming & Design