Multiple Choice
Which of the following will open a file named MyFile.txt and allow you to read data from it?
A) File file = new File("MyFile.txt") ;
B) Scanner inputFile = new Scanner("MyFile.txt") ;
C) File file = new File("MyFile.txt") ;
Scanner inputFile = new Scanner(file) ;
D) PrintWriter inputFile = new PrintWriter("MyFile.txt") ;
Correct Answer:

Verified
Correct Answer:
Verified
Q6: Which of the following are pre-test loops?<br>A)
Q45: This is a sum of numbers that
Q46: Assume that inputFile references a Scanner object
Q48: How many times will the following do-while
Q49: This type of loop is ideal in
Q51: In all but rare cases, loops must
Q52: _ is the process of inspecting data
Q53: This variable controls the number of times
Q54: What will be the value of x
Q55: You can use the PrintWriter class to