给程序修理修理
#include<iostream.h>void fun(int a[],int n,&max,&min)
{
int i,min,max;
max=min=a[0];
for(i=1;i<n;i++)
{
if(max<a[i])
max=a[i];
if(min>a[i])
min=a[i];
}
}
void main()
{
int max,min;
int x[10]={25,55,45,33,88,11,55,66,77,22};
fun(x,10,max,min);
cout<<"max:="<<max<<endl;
cout<<"min:="<<min<<endl;
}