当前位置:计算机科学技术题库>CPP考试题库

问题:

[单选] 1)#include 2)using namespace std; 3)int main() 4){ 5)int a,b,result; 6)couta>>b; 8)result=3*a-2*b+1; 9)cout

A、代表’’和’n’两个字符。B、回车,即回到当前行的行首。C、回车换行,即回到下一行首列。D、制表符。

问题:

[单选] 1)#include 2)using namespace std; 3)int main() 4){ 5)int a,b,result; 6)couta>>b; 8)result=3*a-2*b+1; 9)cout

A、Iamastudent.的前面。B、Iamastudent.的后面。C、Iamastudent.的下一行首列。D、不确定。

问题:

[单选] 1)#include 2)using namespace std; 3)int main() 4){ 5)int a,b,result; 6)cout<<"please input two numbers: "; 7)cin>>a>>b; 8)result=3*a-2*b+1; 9)cout<<"resultis

A、cout<;<;&rdquo;Iamastudent.\n”。B、";Iamastudent.\n&rdquo;。C、Iamastudent.。D、Iamastudent.。

问题:

[单选] 1)#include 2)using namespace std; 3)int main() 4){ 5)int a,b,result; 6)couta>>b; 8)result=3*a-2*b+1; 9)cout

A、第3行。B、第4行。C、第5行。D、第6行。

问题:

[单选] 1)#include < iostream > 2)# include < math.h > 3)using namespace std; 4)double max(double x,doubley); 5)void main() 6){ 7)double   a,b,c; 8)cout << " input two numbers: "; 9)cin>>a>>b; 10)c=max(a,b); 11)cout<< " the squart of max imum="<< sqrt(c); 12)} 13)double max(doublex,doubley) 14){ 15)if(x>y) 16)returnx; 17)else 18)returny; 19)}若执行第9行时,输入89后按回车,则程序第11行输出:()

A.the squart of max imum=sqrtC.。the squart of max imum=3.08221。the squart of max imum=3。the squart of max imum=9.0。

问题:

[单选] 1)#include2)#include3)usingnamespacestd;4)doublemax(doublex,doubley);5)voidmain()6){7)double  a,b,c;8)couta>>b;10)c=max(a,b);11)cout

A、求c的绝对值。B、求c的平方。C、求c的开平方。D、将c进行类型转换。

问题:

[单选] 1)#include < iostream > 2)# include < math.h > 3)using namespace std; 4)double max(double x,doubley); 5)void main() 6){ 7)double   a,b,c; 8)cout >a>>b; 10)c=max(a,b); 11)cout

A.#include。#include。using namespace std;

问题:

[单选] 1)#include < iostream > 2)# include < math.h > 3)using namespace std; 4)double max(double x,doubley); 5)void main() 6){ 7)double   a,b,c; 8)cout >a>>b; 10)c=max(a,b); 11)cout

A、1个。B、2个。C、3个。D、4个。

问题:

[单选] 1)#include < iostream > 2)# include < math.h > 3)using namespace std; 4)double max(double x,doubley); 5)void main() 6){ 7)double   a,b,c; 8)cout >a>>b; 10)c=max(a,b); 11)cout

A、整型。B、单精度浮点型。C、双精度浮点型。D、字符型。

问题:

[单选] 1)#include < iostream > 2)# include < math.h > 3)using namespace std; 4)double max(double x,doubley); 5)void main() 6){ 7)double   a,b,c; 8)cout >a>>b; 10)c=max(a,b); 11)cout

A.0。1。变量不存在。随机值。