标签:exception div ring 不能 try ati row oid throws
package zuizhong; public class Test5 { public static void main(String[] args) throws Exception { try { int s=divide(100, 0); } catch (Exception e) { throw e; } } public static int divide(int a,int b) throws Exception{ if(b==0){ Exception e=new Exception("除数不能为零"); throw e; }else return a/b; } }
标签:exception div ring 不能 try ati row oid throws
原文地址:http://www.cnblogs.com/zyy1130/p/6752385.html