单项选择题

在进行了任何C++流的操作后,都可以用C++流的有关成员函数检测流的状态;其中( )函数名只能用于检测输入操作。

A.bad()
B.good()
C.fail()
D.eof()
<上一题 目录 下一题>
热门 试题

单项选择题
下面的符号中不属于C++关键字的是( )。
A.friend
B.byte
C.continue
D.namespace
单项选择题
若磁盘上已存全路径文件名为c: ctest test.txt的文件,下面语句中不能打开该文件的是( )。
A.ifstream *pFile=new ifstream("c:\\ctest\\test.txt");
B.ifstream file("c:\\ctest\\test.txt");
C.ifstream file;file.open("c:\\ctest\\test.txt");
D.ifstream file("c:\etest\test.txt");
相关试题
  • 有如下程序; #include <iostream> u...
  • 执行如下程序将输出( ): #include<i...
  • 有如下程序: #include<iostream> usi...
  • 有如下程序: #include<iostream> #i...
  • 执行下面语句后,输出字符 # 的个数是(...