?????函数不起作用

# include<stdio.h>
int main()
{
void swap(int x,int y);
int a,b,c,n,i,j=0,t,max=-1;
scanf("%d %d %d %d",&n,&a,&b,&c);
if(a>b){swap(a,b);}
if(a>c){swap(a,c);}
if(b>c){swap(b,c);}



printf("%d %d %d",a,b,c);
printf("%d",max);
return 0;

}

void swap(int x,int y)
{
int t;
t=x;
x=y;
y=t;
}

原文地址:https://www.cnblogs.com/wshyj/p/6052360.html