计算机二级题库
提供计算机二级相关考试试题、历年真题、模拟试题和答案解析,支持在线查看与练习。
最新收录试题
单选题
计算机二级
有如下程序:
#include<iostream>
usingnamespacestd;
classCon
charID;
public:
Con():ID(
2013-08-06
收藏 0 次
单选题
计算机二级
对于模板定义关键字class和typename说法不正确的是( )。
2013-08-06
收藏 0 次
单选题
计算机二级
以下程序的输出结果是( )。
#include<iostream.h>
longfun(intn)
{longS;
if(n==1‖n==2)s=2;
els
2013-08-06
收藏 0 次
单选题
计算机二级
下列关于纯虚函数与抽象类的描述中,错误的是( )。
2013-08-06
收藏 0 次
单选题
计算机二级
有如下程序:
#include<iostream>
usingnamespacestd;
classTest
{
public:
Test(){n+=2;}
~
2013-08-06
收藏 0 次
单选题
计算机二级
有如下程序:
#include<iostream>
usingnamespacestd;
classBASE{
public:
~BASE(){cout<
2013-08-06
收藏 2 次
单选题
计算机二级
已知枚举类型定义语句为
enHmToken{NAME,NUMBER,PLUS=5,MINUS,PRINT=10};
则下列叙述中错误的是( )。
2013-08-06
收藏 3 次
单选题
计算机二级
有如下程序:
#include<iostream.h>
usingnamespacestd;
classBase
{
public:
Base(){cout&l
2013-08-06
收藏 0 次
单选题
计算机二级
有如下程序:
#included<iostream>
usingnamespqcestd;
classTestClass
{
private;
charC;
2013-08-06
收藏 0 次
单选题
计算机二级
有如下程序:
#include<iostream>
usingnamespacestd;
classTestClass
{public:
virtualvoid
2013-08-06
收藏 0 次
单选题
计算机二级
以下类定义中可能会引起错误的语句是( )。
classA
{
public:
~A( ){}//1
inti;//2
private:
intj;//3
A(inti)
2013-08-06
收藏 0 次
单选题
计算机二级
以下不能正确创建输出文件对黎并使其与磁盘文件相关联的语句是( )。
2013-08-06
收藏 0 次
单选题
计算机二级
下列程序的输出结果是( )。#include<iostream.h>
voidmain()
(char*str="12123434";
intx1=0,x2=0
2013-08-06
收藏 0 次
单选题
计算机二级
有以下程序:
#include<iostream>
usingnamespacestd;
classA
{private:
inta:
public:
A(i
2013-08-06
收藏 0 次
单选题
计算机二级
下列关于模板的说法正确的是( )。
2013-08-06
收藏 1 次
单选题
计算机二级
有如下语句序列:
intk=0:
do{k+=5;cout<<'$';}whilc(k<19);
while(k->O)cout<<'*'
2013-08-06
收藏 0 次
单选题
计算机二级
重载输人流运算符>>必须使用的原型为( )。
2013-08-06
收藏 1 次
单选题
计算机二级
有如下程序:
#included<iostream>
usingnamespacestd;
classA{
public:
virtualvoidfuncl()
2013-08-06
收藏 1 次
单选题
计算机二级
派生类对象对其基类中的什么成员是可访问的?( )
2013-08-06
收藏 0 次
单选题
计算机二级
下列关于运算符重载不正确的是( )。
2013-08-06
收藏 0 次