1
1
mirror of https://github.com/github/semantic.git synced 2024-12-29 09:55:52 +03:00
semantic/test/fixtures/java/corpus/TryCatches.A.java

20 lines
569 B
Java
Raw Normal View History

2018-06-02 00:09:56 +03:00
class Example2{
public static void main(String args[]){
try{
int a[]=new int[7];
a[4]=30/0;
System.out.println("First print statement in try block");
}
catch(ArithmeticException e){
System.out.println("Warning: ArithmeticException");
}
catch(ArrayIndexOutOfBoundsException e){
System.out.println("Warning: ArrayIndexOutOfBoundsException");
}
catch(Exception e){
System.out.println("Warning: Some Other exception");
}
System.out.println("Out of try-catch block...");
}
}