?? finallyworks.java
字號:
package chapter12;
class ThreeException extends Exception{
}
public class FinallyWorks {
static int count=0;
public static void main(String args[]){
while(true){
try{
if(count++==0){
throw new ThreeException();
}
System.out.println("No exception");
}catch(ThreeException e){
System.out.println("Three Exceptions");
}finally{
System.out.println("In the finally clause");
if(count==2){
break;
}
}
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -