试题通
试题通
APP下载
首页
>
财会金融
>
c语言冲就完事了家人们
试题通
搜索
c语言冲就完事了家人们
题目内容
(
单选题
)
7.已知int x=10;float y=20;double z=30;,则表达式x+y+z的数据类型是______。

A、  int

B、  float

C、  double

D、  无法确定

答案:C

试题通
c语言冲就完事了家人们
试题通
15.以下不能对一维数组a进行正确定义及初始化的语句是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-95b0-c044-ce3414c8e900.html
点击查看题目
17.以下程序段的输出结果是______。
char s[]="Hello World!";
strlwr( );
printf( );
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-9398-c044-ce3414c8e901.html
点击查看题目
18.max函数的功能是求整型数组a中前n个元素中的最大值。下列函数声明语句中错误的是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-4190-c044-ce3414c8e900.html
点击查看题目
23.设有:
#define ADD( ) x+y
则语句
printf("s=%d", 5*ADD(4,3));
的输出结果是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-a550-c044-ce3414c8e901.html
点击查看题目
17.设有char s[2][10]={"12","34"};,则数组s占用______个字节。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-43a8-c044-ce3414c8e901.html
点击查看题目
12.设n为整型变量,执行语句for(n=1;n++<4;);后,变量n的值是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-8de0-c044-ce3414c8e901.html
点击查看题目
15.设有定义:int a[5];,则对a数组元素引用不正确的是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-8fb0-c044-ce3414c8e900.html
点击查看题目
12.执行下列程序后,输出的结果是______。
#include
void main( )
{
int i,s=0;
for(i=1;i<10;i+=2)
s+=i+1;
printf( );
}
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-e3d0-c044-ce3414c8e900.html
点击查看题目
18.已知主调函数中有以下定义及声明:
int a=1,b=2;float fun( );
则在主调函数中可以正确调用此函数的语句是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e9d0-c044-ce3414c8e901.html
点击查看题目
9.设有以下语句:char c1,c2;scanf("%c%c",&c1,&c2);,若要为变量c1和c2分别输入字符A和B,正确的输入形式应该是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-89f8-c044-ce3414c8e900.html
点击查看题目
首页
>
财会金融
>
c语言冲就完事了家人们
题目内容
(
单选题
)
手机预览
试题通
c语言冲就完事了家人们

7.已知int x=10;float y=20;double z=30;,则表达式x+y+z的数据类型是______。

A、  int

B、  float

C、  double

D、  无法确定

答案:C

试题通
试题通
c语言冲就完事了家人们
相关题目
15.以下不能对一维数组a进行正确定义及初始化的语句是______。

A.  int a[5]={ };

B.  int a[5]={1};

C.  int a[5]={1,2};

D.  int a[5]={1,2,3,4,5};

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-95b0-c044-ce3414c8e900.html
点击查看答案
17.以下程序段的输出结果是______。
char s[]="Hello World!";
strlwr( );
printf( );

A.   hello world!

B.   HELLO world!

C.   hello WORLD!

D.   HELLO WORLD!

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-9398-c044-ce3414c8e901.html
点击查看答案
18.max函数的功能是求整型数组a中前n个元素中的最大值。下列函数声明语句中错误的是______。

A.   int max(int *a,int n);

B.   int max(int a[10],int n);

C.   int max(int a,int n);

D.   int max(int a[ ],int n);

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-4190-c044-ce3414c8e900.html
点击查看答案
23.设有:
#define ADD( ) x+y
则语句
printf("s=%d", 5*ADD(4,3));
的输出结果是______。

A.   s=35

B.   s=12

C.   s=23

D.   s=17

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-a550-c044-ce3414c8e901.html
点击查看答案
17.设有char s[2][10]={"12","34"};,则数组s占用______个字节。

A.   2

B.   10

C.   20

D.   4

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-43a8-c044-ce3414c8e901.html
点击查看答案
12.设n为整型变量,执行语句for(n=1;n++<4;);后,变量n的值是______。

A.   3

B.   4

C.   5

D.   6

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-8de0-c044-ce3414c8e901.html
点击查看答案
15.设有定义:int a[5];,则对a数组元素引用不正确的是______。

A.  a[5]

B.  a[3*1]

C.  a[10-10]

D.  a[3+1]

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-8fb0-c044-ce3414c8e900.html
点击查看答案
12.执行下列程序后,输出的结果是______。
#include
void main( )
{
int i,s=0;
for(i=1;i<10;i+=2)
s+=i+1;
printf( );
}

A.   s=30

B.   s=25

C.   s=55

D.   s=45

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-e3d0-c044-ce3414c8e900.html
点击查看答案
18.已知主调函数中有以下定义及声明:
int a=1,b=2;float fun( );
则在主调函数中可以正确调用此函数的语句是______。

A.   fun(a);

B.   fun(a,&b);

C.   fun(*a,*b);

D.   fun(&a,a+b);

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e9d0-c044-ce3414c8e901.html
点击查看答案
9.设有以下语句:char c1,c2;scanf("%c%c",&c1,&c2);,若要为变量c1和c2分别输入字符A和B,正确的输入形式应该是______。

A.   A和B之间用逗号分隔

B.   A和B之间不能有任何分隔符

C.   A和B之间可以用回车分隔

D.   A和B之间用空格分隔

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-89f8-c044-ce3414c8e900.html
点击查看答案
试题通小程序
试题通app下载