Skip to content

Commit fbbfb31

Browse files
authored
Add files via upload
1 parent ab2fdce commit fbbfb31

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

Diff for: Exception Handling/ControlFlow1.java

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
2+
/**
3+
* ExceptionHandling1
4+
*/
5+
class ControlFlow1 {
6+
public static void main(String[] args) {
7+
int d;
8+
try{
9+
d=0;
10+
int a=42/d;
11+
System.out.println("Inside Try block");
12+
}
13+
catch(ArithmeticException e){
14+
System.out.println(e);
15+
}
16+
System.out.println("After catch");
17+
}
18+
}

0 commit comments

Comments
 (0)