题目内容

Given the fragmented definition of the A class.class A{public:A(int x, int y): num1(x), num2(y){}private:int num1, num2;};int main(){A a(3, 4);double d = a + 5.4;int n = 5 + int(a);}How to work with the A class to make the main function be executed successfully?

查看答案
更多问题

下面哪个选项可以判断出字符变量ch(char ch)是否为数字字符 ?

A. 0= B. '0'= C. ch>=0&&ch<=9
D. ch>='0'&&ch<='9'

下面哪个选项可以判断出字符变量ch(char ch)是否为空格 ?

A. ch=' '
B. ch==' '
C. ch=='\n'
D. ch=='0'

如果字符变量c中的字符为大写英文字母,则转化为小写英文字母的语句是()。

A. c+32
B. c+26
C. c=c+26
D. c=c+32

判断一个整数是否为偶数的条件是?...int a;scanf("%d",&a);if(_______)printf("%d是一个偶数",a);elseprintf("%d不是一个偶数",a);...

A. a/2==0
B. a%2==0
C. a%2==1
D. a/2==1

答案查题题库