单项选择题

下列哪种异常是检查型异常,需要在编写程序时声明()。

A.NullPointerException
B.ClassCastException
C.FileNotFoundException
D.IndexOutOfBoundsException