A.开中断,并允许定时计数器T0溢出中断,且将其设为最高优先级
B.打开所有中断,并将定时计数器T1溢出中断设为最高优先级
C.开中断,并允许定时计数器T1溢出中断,且将其设为最高优先级
D.打开所有中断,并将定时计数器T0溢出中断设为最高优先级
第1题
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->x
第2题
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->x
第3题
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->x
第4题
struct st
{int x;int*y;}*pt;
int a[]={1,2},b[]={3,4};
stmct st c[2]={10,a,20,b};
pt=c;
下列选项中表达式的值为11的是( )。
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->X
第5题
A.*pt- >y
B.pt- >x
C.+ +pt- >x
D.(pt+ +)->x
第6题
请改正程序中的错误,使它能得出正确的结果。
注意:不要改动main()函数,不得增行或者删行,也不得改变程序的结构!
试题程序:
include <conio.h>
include <string.h>
include <stdio.h>
void fun(char str[][10],int m,char *pt)
{
int k,q,i,j=0;
/*************found*************/
for(k=m;k>0;k--)
{
q=strlen(str[k]);
j+=q;
for(i=0;i<q;i++)
pt[i]=str[k][i];
pt+=q;
pt[0]=0;
}
/*************found**************/
pt=j;
}
main()
{int m,h;
char s[10][10],p[120];
clrscr();
printf("\nPlease enter m:");
scanf("%d",& m);
printf("\nPlease enter%d string:\n",m);
gets(s[0]);
for(h=0;h<m;h++)
gets(s[h]);
fun(S,m,p);
printf("/nThe result iS:%s\n",p);
}
第7题
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->X
第8题
A.*pt->y
B.pt->x
C.++pt->x
D.(pt++)->x
第9题
请改正程序中的错误,使它能得出正确的结果。
注意:不要改动main函数,不得增行或删行,也不得更改程序的结构。
试题程序:
include <conio.h>
include <string.h>
include <stdio.h>
/*************found**************/
int fun(char str[] [10],int m, char *pt)
{ int k,q,i,j=0;
for(k=0;k<m;k++)
{ q=strlen(str[k]);
j+=q;
for(i=0;i<q;i++)
/*************found**************/
pt[i]=str[k,i];
pt+=q;
pt[0] =0;
}
pt-=j;
}
main ( )
{ int m, h;
char s[10] [10],p[120];
clrscr ();
printf("\nPlease enter m: ");
scanf("%d",&m); gets(s[0]);
printf ("\nPlease enter %d string:In ",m);
for(h=0;h<m;h++) gets(s[h]);
fun (s,m,p);
printf("\nThe result is :%s\n ",p);
}
第10题
include<stdi0.h>
definePT3.5;
defineS(x)PT*x*x;
voidmain( )
(inta=1.b=2;printf("%4.1f\n",S(a+b));}
程序运行后的输出结果是( )。
A.14.0
B.31.5
C.7.5
D.程序有错,无输出结果
为了保护您的账号安全,请在“上学吧”公众号进行验证,点击“官网服务”-“账号验证”后输入验证码“”完成验证,验证成功后方可继续查看答案!