with Complete Solutions
Which of the following is NOT a component of a try block?
a. a closing curly brace
b. the keyword
c. executable statements
d. a throw statement
REFERENCES:
599 ✔️✔️d. a throw statement
A(n) ____ clause is used in the method header so that applications that use your methods are
notified of the potential for an exception.
a. throws
b. return
c. stack
d. exception
REFERENCES:
624 ✔️✔️a. throws
In order to use a variable both with a try or catch block and afterward, you must declare the
variable before the ____ block begins.
a. catch
b. try
c. main
d. finally
REFERENCES:
, 606 ✔️✔️b. try
In the case where a method might throw more than one exception type, you specify a list of
potential exceptions in the method header by separating them with ____.
a. spaces
b. semicolons
c. commas
d. periods
REFERENCES:
625 ✔️✔️c. commas
The ___________ class comprises less serious errors that represent unusual conditions that
arise while a program is running and from which the program can recover.
REFERENCES:
595 ✔️✔️Exception
If you create an object using Java's BigDecimal class, and then perform a division that results in
a non-terminating decimal division such as 1/3, but specify that an exact result is needed, a(n)
__________ is thrown.
REFERENCES:
603 ✔️✔️Arithmetic Expression
Any _____ block might throw an Exception for which you did not provide a catch block.
REFERENCES:
616 ✔️✔️try
The memory location known as the __________ is where the computer stores the list of
method locations to which the system must return.