[Solved] Programming Challenges 110106 [closed]
I think you problem may be here while (input.hasNext()) { int num = Integer.parseInt(input.next()); if (input.next() == “”) { The second line reads an input, but so does the next line. So when the loop is at the last element, the first line will read it, then the next line will try to read a … Read more