Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class TestFinally{
- public int test(){
- try {
- throw new Exception();
- } catch (Exception npe){
- System.out.println("Exception");
- //return 0;
- System.exit(0);
- } finally{
- System.out.println("Finally");
- }
- return 0;
- }
- static public void main(String args[]){
- System.out.println("Hello");
- Main main = new Main();
- int i = main.test();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement