Hi Gowher,
Your finally Block has a call to a method which inturn throws an exception. This exception is not caught . Any uncaught exception is handled by the default handler provided by the java run-time system. This prints the exception and terminates the program and the function you called in the finally block is never returned. so whatever you do after the call to the fucntion m() will not be executed.
just add a try-catch in method m as given below
static void m()throws Exception{
try {
throw new Exception();
} catch(Exception e) {
System.out.println("Caught");
}
}