Questions from Starting Out With Java


Q: Examine the following method header, and then write an example call

Examine the following method header, and then write an example call to the method: public static void doSomething(int x)

See Answer

Q: What is the difference between a text file and a binary file

What is the difference between a text file and a binary file?

See Answer

Q: What classes do you use to write output to a binary file

What classes do you use to write output to a binary file? What classes do you use to read from a binary file?

See Answer

Q: What is the difference between sequential and random access?

What is the difference between sequential and random access?

See Answer

Q: What class do you use to work with random access files?

What class do you use to work with random access files?

See Answer

Q: What are the two modes that a random access file may be

What are the two modes that a random access file may be opened in? Explain the difference between them.

See Answer

Q: What must you do to a class in order to serialize objects

What must you do to a class in order to serialize objects of that class?

See Answer

Q: If an exception is thrown and the program does not handle it

If an exception is thrown and the program does not handle it, what happens?

See Answer

Q: Other than the Object class, what is the superclass for all

Other than the Object class, what is the superclass for all exceptions?

See Answer

Q: What is the difference between exceptions that inherit from the Error class

What is the difference between exceptions that inherit from the Error class and exceptions that inherit from the Exception class?

See Answer