Multiple Choice
Insert the missing code in the following code fragment. This fragment is intended to read binary data. public static void main(String[] args) throws IOException
{
String address = "http://horstmann.com/bigjava.gif";
URL imageLocation = _________;
InputStream in = imageLocation.openStream() ) ;
) . .
}
A) new Scanner("http://horstmann.com/bigjava.gif")
B) new Scanner(address)
C) new imageLocation.openStream
D) new URL(address)
Correct Answer:

Verified
Correct Answer:
Verified
Q16: Assume that inputFile is a Scanner object
Q17: You wish to use the Scanner class's
Q18: Insert the missing code in the following
Q19: Consider the following code snippet: Scanner in
Q20: Which method of an exception object will
Q22: Consider the following code snippet: Scanner in
Q23: Assuming that inputFile is a Scanner object
Q24: Consider the following code snippet: throw new
Q25: Which statement about handling exceptions is true?<br>A)
Q101: The _ method of the Character class