【简答题】【消耗次数:1】
int a[10]={0,1,2,3,4,5,6,7,8,9};int *p;int i;p=a;printf(%d\n,*p++);printf(%d\n,*++p);程序输出结果为[填空1]和[填空2]。
参考答案:
复制
纠错
相关题目
【简答题】 #includestdio.hint main(){int a[10]={0,1,2,3,4,5,6,7,8,9};int *p;p=a;printf(%d\n,*p);p++;printf(%d\n,*p);}程序输出结果为[填空1]和[填空2]。
【单选题】 下述程序的运行结果( )。 #includevoid main() { int p,a=0; if(p=a!=0)printf(%d\n else printf(%d\n,p+2); }
①  1
②  2
③  3
④  5
【单选题】 以下程序运行的输出结果是。main(){ int p=30;printf(%d\n,(p/320?p/10:p%3)); }
①  0
②  1
③  2
④  3
【简答题】 #include stdio.hint main(){void swap(int *p1,int *p2);int a,b;int*pointer_1,*pointer_2;printf(please enter a and b:scanf(%d,%d,a,pointer_1=pointer_2=if(ab) swap(pointer_1,pointer_2);printf(%d,%d\n,a,b);return 0;} void swap(int *p1,int *p2){int temp;temp=*p1;*p1=*p2;*p2=temp;}若输入5,9,则输出为[填空1]。
【简答题】 #include stdio.hint main(){void swap(int *p1,int *p2);int a,b;int*pointer_1,*pointer_2;printf(please enter a and b:scanf(%d,%d,a,pointer_1=pointer_2=if(ab) swap(pointer_1,pointer_2);printf(%d,%d\n,a,b);return 0;} void swap(int *p1,int *p2){int * temp;temp=p1;p1=p2;p2=temp;}若输入5,9,则输出为[填空1]。
【单选题】 以下程序的运行结果是()。main(){inta[3]={1,2,3};int*num[3];int**p,i;for(i=0;ii++)num[i]=p=num;printf("%d",**p);}
①  1
②  3
③  a[0]
④  num
【单选题】 以下程序的输出结果是_______? f(int b[],int m,int n) { int i,s=0; for(i=m;in;i=i+2) s=s+b[i]; return s; } int main() { int x,a[]={1,2,3,4,5,6,7,8,9}; x=f(a,3,7); printf(%d\n,x); }
①  7
②  8
③  9
④  10
【简答题】 查找n在数组a中最后一次出现的位置(数组首元素的位置为零)。 例如:如果a数组中的元素为:1,5,2,5,6,8,7,4,3,0, 当n=5时,程序的输出结果为:5 is No.3 。 当n=10时,程序的输出结果应为:10 not found !。 #includevoid main( ) { int a[10]={1,5,2,5,6,8,7,4,3,0}; int i,k,n,f=0; scanf(%d, for(i=0;ii++) /************found************/ if([填空1]) { f=1; /************found************/[填空2] } if(f) printf(%d is No. %d\n, n,k); else printf( %d not found !\n }
【单选题】 有以下程序,执行后输出结果是() main( ) { int m[][3]={1,4,7,2,5,8,3,6,9}; int i,j,k=2; for(i=0;i { printf(%d ,m[k][i]); } }
①  4 5 6
②  2 5 8
③  3 6 9
④  7 8 9
【单选题】 已知int a[10]={0,1,2,3,4,5,6,7,8,9},*p=a;不能表示数组a中元素的式子是()
①  *a
②  *p
③  a
④  a[p-a]
随机题目
【单选题】 变压器负载运行时,随着负载电流的增大,其铁心损耗<imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205100008_669.png"/>和铜损耗<imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205100015_370.png"/>会()
①  <imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205095339_393.png"/>增大,<imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205095346_882.png"/>不变
②  <imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205095355_176.png"/>不变,<imgalt=""src="http://wljy.whut.edu.cn:80/uploadfiles/kindeditorAttached/image/20191205/20191205095359_427.png"/>增大
③  都会增大
【多选题】 压焊的方法较多,其中最常用的有
①  电阻焊
②  磨擦焊
③  扩散焊
【多选题】 面积较大的薄壁部分置于铸型()
①  下部
②  倾斜
③  侧立
【多选题】 以零件图为基础,分为
①  冷锻件图
②  热锻件图
【判断题】 机械应力和相变应力三者的代数和
①  正确
②  错误
【判断题】 容积大而集中的称为缩孔,细小而分散的称为缩松。
①  正确
②  错误
【判断题】 铸造是一种液态金属成形的方法
①  正确
②  错误
【判断题】 铸件按“同时凝固”原则进行凝固
①  正确
②  错误
【判断题】 浇注位置:浇注时铸件在铸型中所处的空间位置。
①  正确
②  错误
【判断题】 金属由液态转变为固态的过程称为气化
①  正确
②  错误