#include <stdio.h>void swap(/**/ int *p1,int *p2 /**/) { int sum; sum = *p1+*p2; *p1 =/**/*p2 /**/; *p2 = sum-*p1;}void main(){ int x,y; printf("please input 2 numbers:\n"); scanf("%d,%d",&x,&y); printf("\nOriginal: x=%d y=%d\n",x,y); swap(&x,&y); printf("\nNow: x=%d y=%d\n",x,y); getch();}不太懂第二个空填什么,求大神指点下,谢谢。
添加回答
举报
0/150
提交
取消