Scanning text file into array of objects
问题 I have a comma separated text file with information in the format: firstname,lastname,meal1,meal2,meal3,meal4 ....with each new student on a new line. I have the following student object. public class Student { private String first = null; private String last = null; public Student (String first, String last){ this.first = first; this.last = last; } I need a method that is to be used from another class to populate an Array of student objects. I am unsure how to do this with the Scanner as I