单选题
运行下列程序时,若没有test.dat文件,则______。
import
java.io.*;
public class Test{
public static
void main(String[] args){
try{
RandomAccessFile raf=new RandomAccessFile("test.dat","r");
System.out.println("test.dat");
}
catch(IOException ex){
System.out.println("exception");
}
}
}
- A.输出exception
- B.输出test.dat
- C.输出IOException
- D.无显示