Exam 21: Advanced Input/Output
Exam 1: Introduction76 Questions
Exam 2: Using Objects82 Questions
Exam 3: Implementing Classes108 Questions
Exam 4: Fundamental Data Types124 Questions
Exam 5: Decisions119 Questions
Exam 6: Loops107 Questions
Exam 7: Arrays and Array Lists117 Questions
Exam 8: Designing Classes88 Questions
Exam 9: Inheritance99 Questions
Exam 10: Interfaces100 Questions
Exam 11: Input/Output and Exception Handling108 Questions
Exam 12: Object-Oriented Design104 Questions
Exam 13: Recursion99 Questions
Exam 14: Sorting and Searching100 Questions
Exam 15: The Java Collections Framework102 Questions
Exam 16: Basic Data Structures102 Questions
Exam 17: Tree Structures102 Questions
Exam 18: Generic Classes75 Questions
Exam 19: Stream Processing85 Questions
Exam 20: Graphical User Interfaces75 Questions
Exam 21: Advanced Input/Output90 Questions
Exam 22: Multithreading81 Questions
Exam 23: Internet Networking74 Questions
Exam 24: Relational Databases75 Questions
Exam 25: XML74 Questions
Select questions type
In ____________ file access, the file is processed starting from the beginning.
(Multiple Choice)
5.0/5
(33)
Every object is assigned a serial number on the stream.What might be the result if the same object is saved twice?
(Multiple Choice)
4.9/5
(33)
What type is returned from a call to the ObjectInputStream.readObject method when reading a String from an object stream?
(Multiple Choice)
4.9/5
(42)
How many bytes does the read method in the FileInputStream class get from the file?
(Multiple Choice)
4.8/5
(36)
Assume we have a RandomAccessFile object, file, that stores a set of records of class MyData.The size of each record is MyData.RECORD_SIZE.Assume MyData has read and write methods both of which take a RandomAccessFile as an argument.Method write writes the object at the current location.Method read reads the record from current location of the file into the object.If we are currently at the beginning of the 1st record, which code correctly modifies the 2nd record by changing its color to Color.red through the setColor method?
(Multiple Choice)
4.8/5
(32)
The readDouble and writeDouble methods of the RandomAccessFile class, process double precision floating-point numbers as ____ quantities.
(Multiple Choice)
4.7/5
(41)
Which code moves the file pointer to the middle of a RandomAccessFile object, file?
(Multiple Choice)
4.9/5
(34)
When storing numbers in a file with fixed record sizes, it is easier to store them in __________ format.
(Multiple Choice)
4.8/5
(37)
Which of the following classes are used with data in binary form?
i.FileInputStream
II.FileReader
III.RandomAccessFile
(Multiple Choice)
4.7/5
(37)
Caesar cipher uses a shift of each character by a key with a value between 1 and 255.An a with a shift equal to 3 becomes a d.For the decrypt method below, select the correct body.Assume the key shift property is accessible to the method.
public int decrypt(int b)
{
__________
}
(Multiple Choice)
4.9/5
(45)
Given a RandomAccessFile that stores a set of records of class MyData, each needing MyData.RECORD_SIZE bytes for storage, which expression gets the offset to the beginning of the 25th record?
(Multiple Choice)
4.9/5
(32)
Which statement is NOT correct about the OutputStream.write method?
(Multiple Choice)
4.8/5
(40)
Fill in the blank in the following code snippet to create an object for writing binary data to a disk file, named output.bin?
try (______________________________)
{
Process output
}
(Multiple Choice)
4.9/5
(44)
Which of the following classes are related through inheritance?
i.InputStream
II.InputStreamReader
III.ObjectInputStream
(Multiple Choice)
4.7/5
(38)
In text format, data items are represented in human-readable form, as a sequence of ____________________.
(Multiple Choice)
4.9/5
(36)
Showing 21 - 40 of 90
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)