填空题

下面程序和运行运行结果是 【18】 。
  void swap(int * a,int * b)
  { int * t;
   t=a; a=b; b=t;
  }
  main( )
  { intx=3,y=5,* p=&x,* q=&y;
   swap(p,q);
   prinff("%d %d\n", *p, *q);}

【参考答案】

【18】3 5
<上一题 目录 下一题>
热门 试题

填空题
若fp已正确定义为一个文件指针,d1.dat为二进制文件,请填空,以便为“读”而打开此文件:fp=fopen【20】 ;。
填空题
fun( )函数的功能是首先对a所指的N行N列的矩阵,找出各行中的最大的数,再求这N个最大值中 的最小的那个数作为函数值返回,请填空。 #include<stdio.h> #define N 100 int fun(int( * a)[N]) { in(row,col,max,min; for(row=0;row<N;row++) { for(max=a [row][0],col=1;col<N;col++) if( 【13】 )max=a[row][col]; if(row= =0)min=max; else if( 【14】 )min=max; } return min; }
相关试题
  • 有以下程序: #include main( ) {...
  • 下面程序和运行运行结果是 【19】 。 ...
  • 下面程序和运行运行结果是 【17】 。 ...