catch(NumberFormatException e){
System.out.println("number format exception");
System.out.println(e);
}catch(IllegalArgumentException e){
System.out.println("illegal argument exception");
System.out.println(e);
}catch(Exception e){
System.out.println("other exception");
System.out.println(e);
}
6-1 jmu-Java-06异常-多种类型异常的捕获 (5 分)
最新推荐文章于 2023-04-06 19:15:50 发布