试题通
试题通
APP下载
首页
>
财会金融
>
c语言冲就完事了家人们
试题通
搜索
c语言冲就完事了家人们
题目内容
(
单选题
)
10.下列程序段输出的结果是______。
int a=5,b=4,c=3;
if( ) a=b+c,b=2*c;
else a=b-c,b=3*c;a=b+c;
printf( );

A、  9 6

B、  7 3

C、  1 9

D、  4 2

答案:A

试题通
c语言冲就完事了家人们
试题通
24.设有:
typedef struct ST
{
long a;
int b;
char c[2];
}NEW;
则下面叙述中正确的是_______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-fb40-c044-ce3414c8e901.html
点击查看题目
17.设有char s[2][10]={"12","34"};,则数组s占用______个字节。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-43a8-c044-ce3414c8e901.html
点击查看题目
19函数的形式参数的作用域是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-4790-c044-ce3414c8e900.html
点击查看题目
15.下列对数组s的初始化,其中不正确的是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e5e8-c044-ce3414c8e900.html
点击查看题目
17.字符串常量"\123\n4567"在内存存储所占的字节数是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e9d0-c044-ce3414c8e900.html
点击查看题目
17.下列程序段的运行结果是_______。
int i;
char s[5]={'\0','1','2','3','4'};
for(i=4;s[i]!='\0';i--)
printf( );
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-3da8-c044-ce3414c8e902.html
点击查看题目
22.已知:char b[6],*p=b;,则正确的赋值语句是____。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-f758-c044-ce3414c8e901.html
点击查看题目
8.判断char型变量ch是否为小写字母的正确表达式是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-2e08-c044-ce3414c8e901.html
点击查看题目
2.下列定义语句中,正确的是_______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-2850-c044-ce3414c8e901.html
点击查看题目
7.已知int x=10;float y=20;double z=30;,则表达式x+y+z的数据类型是______。
https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-8610-c044-ce3414c8e900.html
点击查看题目
首页
>
财会金融
>
c语言冲就完事了家人们
题目内容
(
单选题
)
手机预览
试题通
c语言冲就完事了家人们

10.下列程序段输出的结果是______。
int a=5,b=4,c=3;
if( ) a=b+c,b=2*c;
else a=b-c,b=3*c;a=b+c;
printf( );

A、  9 6

B、  7 3

C、  1 9

D、  4 2

答案:A

试题通
试题通
c语言冲就完事了家人们
相关题目
24.设有:
typedef struct ST
{
long a;
int b;
char c[2];
}NEW;
则下面叙述中正确的是_______。

A.   ST是一个结构体类型变量

B.   NEW是一个结构体类型

C.   NEW是一个结构体变量

D.   以上的说明形式非法

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-fb40-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
点击查看答案
19函数的形式参数的作用域是______。

A.   本函数的全部范围

B.   本程序的全部范围

C.   本文件的全部范围

D.   从定义开始至本文件结束

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-4790-c044-ce3414c8e900.html
点击查看答案
15.下列对数组s的初始化,其中不正确的是______。

A.   char s[5] = {"abc"};

B.   char s[5] = { 'a', 'b', 'c'};

C.   char s[5] = "";

D.   char s[5] = "abcdef";

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e5e8-c044-ce3414c8e900.html
点击查看答案
17.字符串常量"\123\n4567"在内存存储所占的字节数是______。

A.   11

B.   10

C.   9

D.   7

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fa-e9d0-c044-ce3414c8e900.html
点击查看答案
17.下列程序段的运行结果是_______。
int i;
char s[5]={'\0','1','2','3','4'};
for(i=4;s[i]!='\0';i--)
printf( );

A.   1234

B.   01234

C.   4321

D.   43210

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-3da8-c044-ce3414c8e902.html
点击查看答案
22.已知:char b[6],*p=b;,则正确的赋值语句是____。

A.   b="abcde";

B.   *b="abcde";

C.   p="abcde";

D.   *p="abcde";

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-f758-c044-ce3414c8e901.html
点击查看答案
8.判断char型变量ch是否为小写字母的正确表达式是______。

A.   'a'<=ch<='z'

B.   ('a'<=ch)||(ch<= 'z')

C.   ('a'<=ch)&&(ch<='z')

D.   ('a'<=ch) and (ch<='z')

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fc-2e08-c044-ce3414c8e901.html
点击查看答案
2.下列定义语句中,正确的是_______。

A.   char a='A' b='B';

B.   float a=b=6.5;

C.   double x=3.4;

D.   int x==y=8;

https://www.shititong.cn/cha-kan/shiti/0005e1ce-a8fb-2850-c044-ce3414c8e901.html
点击查看答案
7.已知int x=10;float y=20;double z=30;,则表达式x+y+z的数据类型是______。

A.   int

B.   float

C.   double

D.   无法确定

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