Computer Applications

Distinguish between the following:

hasNext() and hasNextLine()

Input in Java

22 Likes

Answer

hasNext()hasNextLine()
Returns true if the Scanner object has another token in its input.Returns true if there is another line in the input of the Scanner object.

Answered By

14 Likes


Related Questions