I understand that I need to use hasNextLine() to advance the line - but when i made a reference to hasNextLine(), I'm not sure why it is still not exiting the while loop:
I'm using a scanner here (sc) to read an input file
while(sc.hasNextLine()){
//read post specifications from line
String postspecs = sc.nextLine();
//split line
String[] postspecs_s = postspecs.split(", ");
//create post
reddit.findUser(stripExtension(argfile.getName())).
addPost(postspecs_s[0], PostType.valueOf
(postspecs_s[1]), postspecs_s[2]);
System.out.println("created");
}
postspecswhat does it print?