交换两个变量的值
#include <stdio.h>
void fun(int x,int y)
{ int t;
t=x;x=y;y=t;
}
void main()
{ int a,b;
a=8;
b=3;
fun(&a, &b);
printf("%d %d\n ", a,b);
}
声明:本站所有文章资源内容,如无特殊说明或标注,均为采集网络资源。如若本站内容侵犯了原著者的合法权益,可联系本站删除。
#include <stdio.h>
void fun(int x,int y)
{ int t;
t=x;x=y;y=t;
}
void main()
{ int a,b;
a=8;
b=3;
fun(&a, &b);
printf("%d %d\n ", a,b);
}
声明:本站所有文章资源内容,如无特殊说明或标注,均为采集网络资源。如若本站内容侵犯了原著者的合法权益,可联系本站删除。