Multiple Choice
After the following program is finished, how many bytes are written to the file t.dat? import java.io.*;
Public class Test {
Public static void main(String[] args) throws IOException {
DataOutputStream output = new DataOutputStream(
New FileOutputStream("t.dat") ) ;
Output.writeShort(1234) ;
Output.writeShort(5678) ;
Output.close() ;
}
}
A) 2 bytes.
B) 4 bytes.
C) 8 bytes.
D) 16 bytes.
Correct Answer:

Verified
Correct Answer:
Verified
Q11: When you implement a method that is
Q12: Text I/O <br>Write a program that will
Q13: Suppose the xMethod() is invoked from a
Q14: Show the output of running the class
Q15: Design and use interfaces <br>Write a class
Q17: Design and create GUI applications <br>Write a
Q18: If a class named Student has no
Q19: How can you get the word "abc"
Q20: If a class named Student has a
Q21: What is displayed on the console when