单项选择题

下列函数模板的定义中,合法的是
<上一题 目录 下一题>
热门 试题

单项选择题
有如下程序: #include <iostream> using namespace std; class test private: int a; public: test( )cout<< constructor <<endl; test(int
A.cout<<a<<endl;
test(const test &_test)
a=_test.a;
cout<<"copy constructor"<<endl;

~test()cout<<"destructor"<<endl;
;
int main( )
test A(3)
return 0;

程序的输出结果是A) 3
destructor
B.constructor
destructor
C.copy constructor
destructor
D.3
单项选择题
要定义数组A,使得其中每个元素的数据依次为3、9、4、8、0、0、0,错误的定义语句是
要定义数组A,使得其中每个元素的数据依次为3、9、4、8、0、0、0,错误的定义语句是
相关试题
  • Date
  • 空格
  • 0
  • 下列程序的输出结果为: Ohject id=0 ...
  • friend:Date