19 lines
496 B
Java
19 lines
496 B
Java
package lr13.task_1;
|
|
|
|
public class e7 {
|
|
public static void main(String[] args) {
|
|
try {
|
|
System.out.println("0");
|
|
throw new NullPointerException("ошибка");
|
|
} catch (NullPointerException e) {
|
|
System.out.println("1");
|
|
try {
|
|
throw new ArithmeticException();
|
|
} catch (ArithmeticException e2) {
|
|
System.out.println("2");
|
|
}
|
|
}
|
|
System.out.println("3");
|
|
}
|
|
}
|