What is displayed on the console when running the following program?

```
public class Test {
public static void main(String[] args) {
try {
method();
System.out.println("After the method call");
}
catch (RuntimeException ex) {
System.out.println("RuntimeException");
}
catch (Exception ex) {
System.out.println("Exception");
}
}
public class Test {
public static void main(String[] args) {
try {
method();
System.out.println("After the method call");
}
catch (RuntimeException ex) {
System.out.println("RuntimeException");
}
catch (Exception ex) {
System.out.println("Exception");
}
}
```
a. The program displays NumberFormatException twice.
b. The program displays NumberFormatException followed by After the method call.
c. The program displays NumberFormatException followed by RuntimeException.
d. The program has a compile error.


c. The program displays NumberFormatException followed by RuntimeException.

Computer Science & Information Technology

You might also like to view...

Explain the Simple Query Wizard in Microsoft Access 2016.?

What will be an ideal response?

Computer Science & Information Technology

A layout determines how objects on a form are arranged

Indicate whether the statement is true or false

Computer Science & Information Technology

Define bleed marks.

What will be an ideal response?

Computer Science & Information Technology

The CPU processes instructions written in which one of the following languages?

a. Java b. pseudo code c. machine language d. Visual Basic

Computer Science & Information Technology