你可能喜欢
单项选择题
A. Line 33 must be called within a try block.
B. The exception thrown by method1 in class a is not required to be caught.
C. The method declared on line 31 must be declared to throw a RuntimeException.
D. On line 5 of class a, the call to method2 of class b does not need to be placed in a try/catch block.
多项选择题
A. The application will crash.
B. The code on line 29 will be executed.
C. The code on line 5 of class A will execute.
D. The code on line 5 of class B will execute.
E. The exception will be propagated back to line 27.
单项选择题
A. Line 92 will not execute.
B. The connection will not be retrieved in line 85.
C. The resource connection will not be closed on line 88.
D. The enclosing method will throw an exception to its caller.
单项选择题
A. B
B. The code runs with no output.
C. Compilation fails because of an error in line 12.
D. Compilation fails because of an error in line 15.
E. Compilation fails because of an error in line 18.
单项选择题
A. B
B. The code runs with no output.
C. An exception is thrown at runtime.
D. Compilation fails because of an error in line 15.
E. Compilation fails because of an error in line 18.
F. Compilation fails because of an error in line 19.
单项选择题
A. Exception
B. A Exception
C. A Exception B
D. A B Exception
E. Compilation fails because of an error in line 14.
F. Compilation fails because of an error in line 19.
单项选择题
A. Exception
B. a,b,Exception
C. Compilation fails because of an error in line 20.
D. Compilation fails because of an error in line 14.
E. A NullPointerException is thrown at runtime.
单项选择题
A. c
B. a
C. ab
D. ac
E. bc
F. abc
多项选择题
A. Class a will not compile.
B. Line 46 can throw the unchecked exception TestException.
C. Line 45 can throw the unchecked exception TestException.
D. Line 46 will compile if the enclosing method throws a TestException.
E. Line 46 will compile if enclosed in a try block, where TestException is caught.
单项选择题
A. Compilation of both classes will fail.
B. Compilation of both classes will succeed.
C. Compilation of class a will fail. Compilation of class b will succeed.
D. Compilation of class a will fail. Compilation of class a will succeed.