为了向文件 hello.txt 尾加数据,下列正确创建指向 hello.txt 的流的语句段是( )。
选项:
A:try { OutputStream out = new FileOutputStream ("hello.txt");}catch(IOException e){};
B:try { OutputStream out = new FileOutputStream ("hello.txt",true);}catch(IOException e){};
C:try { OutputStream out = new FileOutputStream ("hello.txt",false);}catch(IOException e){};
D:try { OutputStream out = new OutputStream ("hello.txt",true);}catch(IOException e){}
发布时间:2024-05-12 22:26:57