Which can appropriately be thrown by a programmer using Java SE technology to create a desktop
application?
A. ClassCastException
B. NullPointerException
C. NoClassDefFoundError
D. NumberFormatException
E. ArrayIndexOutOfBoundsException这样的知识点在SCJP study guide 6当中没有提到。估计不会考(谁知道)。但是如果有高手赐教,必将不胜感激。
还有哪些没有列出来的Exception可能被抛出呢?
application?
A. ClassCastException
B. NullPointerException
C. NoClassDefFoundError
D. NumberFormatException
E. ArrayIndexOutOfBoundsException这样的知识点在SCJP study guide 6当中没有提到。估计不会考(谁知道)。但是如果有高手赐教,必将不胜感激。
还有哪些没有列出来的Exception可能被抛出呢?
看看对不对
参考答案可不是这样滴。给出理由,还有出处?thx
C classpath 有问题。答案 D是不是这个
我觉得这个定会抛出
引发NumberFormatException异常:主要原因是将用户提交的内容转换为整数或者浮点数时用户输入了其它非法字符。处理的主要方式是在需要进行转换的地方使用try/catch块捕获此异常然后提示用户输入合法数据。
不用多少,LZ给分吧
ArrayIndexOutOfBoundsException
ClassCastException
NullPointerException
ExceptionInInitializerError
StackOverflowError
NoClassDefFoundErrorBy the programmer:
IllegalArgumentException
IllegalStateException
NumberFormatException
AssertionError