Answer:
110
Explanation:
The Scanner is a Java class that is used to take an input from user.
The nextInt() method will get an integer from user.
The while loop in the question is a sentinel loop where the loop will keep running until user input the sentinel value which is -1 to stop the loop. This is important to note that, before the start of next iteration, the program will prompt the input for an integer from user.
While the loop is ongoing, the variable sum will be repeatedly added with input integer from user. If the input is 18, 25, 61, 6, the sum will be 18 + 25 + 61 + 6 = 110