| Page 15 of 38 Prev | Index | Next |
public class ExException {
public static void main(String[] args) {
try {
int a = 1;
int b = a/0;
} catch (ArithmeticException e) {
e.printStackTrace();
} catch (NullPointerException e) {
e.printStackTrace();
}
}
}
ExException.java
try: a = 1 b = a/0 except (ZeroDivisionError, ValueError, NameError), e: print eex_exception.py