为什么选D呢?uu们

img


不应该是输出 hello throwit finally after吗?

throwit()这个方法里抛出了异常,被main方法里的catch捕捉到了,main里的catch代码也要执行,所以输出 hello throwit caught finally after

因为 try 里面触发了异常,catch 把他 catch 住了,如果没有异常,catch里面不会执行,建议详细阅读下课本。

捕捉的异常是exception,你看一下继承关系,runtimeexception是可以被捕捉到的