Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions exceptionsHandling/PracticeExceptionHandling.java
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
package exceptionsHandling;

public class PracticeExceptionHandling{

public static void main(String[] args){

try{
int a = 7;
int b = 0;
int c = a/b;
System.out.println(c);
}catch(ArithmeticException e){
System.out.println(e.getMessage()+" the value of denomenator can't be 0");
}
finally{
System.out.println("bye bye");
}
}

}