I know how to read a file with Java
using Scanner
and File IOException, but the only thing I don\'t know is how to store the text in the files as a
while(inFile1.hasNext()){
token1 = inFile1.nextLine();
// put each value into an array with String#split();
String[] numStrings = line.split(", ");
// parse number string into doubles
double[] nums = new double[numString.length];
for (int i = 0; i < nums.length; i++){
nums[i] = Double.parseDouble(numStrings[i]);
}
}