Assume that inputFile references a Scanner object that was used to open a file. Which of the following while loops is the correct way to read data from the file until the end of the file is reached?
a. while (inputFile.nextLine == " ")
{ ... }
b. while (inputFile != null)
{ ... }
c. while (!inputFile.EOF)
{ ... }
d. while (inputFile.hasNext())
{ ... }
d. while (inputFile.hasNext())
{ ... }
You might also like to view...
In the Document Settings dialog box, the ____ option matches the size of the Stage to be the same as the printer page size.
A. Match: Print Area B. Match: Default C. Match: Contents D. Match: Printer
What happens when a cable breaks in a star topology network?
What will be an ideal response?
To calculate the number of montly payments required to pay off a loan or meet an investment goal, use the _______ function.
A. PMT B. FV C. PPMT D. NPER
The ____________________ statement is the last line of a For loop.
Fill in the blank(s) with the appropriate word(s).