摘要: 1 #include<stdio.h> 2 void swap(int *p1,int *p2) 3 { 4 int tmp; //注意这里必须是变量而不是指针,访问野指针会出错 5 tmp=*p1; 6 *p1=*p2; 7 *p2=tmp; 8 } 9 int main() 10 { 11 in 阅读全文
posted @ 2020-01-08 16:59 sxdtly 阅读(187) 评论(0) 推荐(0)