【简答题】【消耗次数: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]。
参考答案:
复制
纠错
相关题目
【简答题】 #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(){char a[]=I love China!,b[20],*p1,*p2;p1=a;p2=b; for(;*p1!=\0p1++,p2++)*p2=*p1; *p2=\0// printf(string a is:%s\n printf(string b is:%s\n return 0;}以上程序运行结果为string b is:[填空1]。
【单选题】 有以下变量说明,下面不正确的赋值语句是() int a=5,b=10,c; int ?p1=&a,?p2=&b;
①  ?p2=b;
②  p1=a;
③  p2=p1;
④  c=?p1?(?p2)。
【判断题】 已知:int *p1, *p2= 由此可知变量a的类型是:int *。
①  正确
②  错误
【简答题】 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]。
【单选题】 指针变量p1、p2类型相同,要使p2、p1指向同一变量,哪一个语句是正确的()。
①  p2=*p1;
②  p2=**p1;
③  p2=p1;
④  p2=*p1;
【单选题】 下面代码:int a[5];int *p;a[0]=1;a[1]=2;p=a;*p的值
①  a
②  1
③  2
④  null
【判断题】 p1和p2都指向同一个数组元素时,可以执行p1-p2或p1+p2。
①  正确
②  错误
【单选题】 下述程序的运行结果( )。 #includevoid main() { int p,a=0; if(p=a!=0)printf(%d\n else printf(%d\n,p+2); }
①  1
②  2
③  3
④  5
随机题目
【简答题】 贡献毛益法适用于[填空] 方案的择优决策。
【多选题】 影响预计生产量的因素有()。
①  预计销售量
②  预计期末存货
③  预计期初存货
④  预计采购量
⑤  预计费用
【简答题】 Direction: Fill in the blanks with the phrases given below. Change the form if necessary.[have access to; go off; desperate for; put up with; always the case; give advice; concentrate on; arrive at; make an effort; come in handy]10. I calculated that he would[填空1]the meeting.
【简答题】 Direction: Fill in the blanks with the words given below. Change the form if necessary.[expand; abuse; knowledge; narrative; plantation; property; oppressive; extremely; rebel; abolitionist]5. We must build on our reputation to[填空1]the business.
【简答题】 Directions: Fill in the blanks with the words given below. Change the form if necessary.[fee; react; expand; besides; quantity; stay; highly; device; customer; commercial]4. Our institute has been rapidly[填空1]in the past decade.
【简答题】 比较权责发生制和收付实现制。
【简答题】 什么是会计核算方法?包括哪些?
【简答题】 错账的更正方法有哪些?其适用范围是什么?
【简答题】 会计是以[填空]为主要计量单位,对企事业、机关单位或其他经济组织的经济活动进行连续、系统、全面的反映和监督的一项经济管理活动。
【简答题】 [填空]是账户的名称,同时也是各单位设置账户的一个重要依据。