摘要: 1、 #include <stdio.h> #define NUMBER 6 typedef struct{ char name[128]; double height; double weight; }Type1; int main(void) { FILE *fp; fp = fopen("xx 阅读全文
posted @ 2021-06-07 21:45 小鲨鱼2018 阅读(50) 评论(0) 推荐(0) 编辑
摘要: 1、 #include <stdio.h> #include <string.h> typedef struct{ char name[128]; double height; double weight; }Type1; void swap2(Type1 *x, Type1 *y) { Type1 阅读全文
posted @ 2021-06-07 19:01 小鲨鱼2018 阅读(40) 评论(0) 推荐(0) 编辑
摘要: 1、 #include <stdio.h> typedef struct{ char name[128]; double height; double weight; }Type1; void swap(Type1 *x, Type1 *y) { Type1 tmp = *x; *x = *y; * 阅读全文
posted @ 2021-06-07 18:44 小鲨鱼2018 阅读(35) 评论(0) 推荐(0) 编辑
摘要: 1、 #include <stdio.h> typedef struct{ char name[128]; double height; double weight; }Typex; void swap(Typex *x, Typex *y) { Typex tmp = *x; *x = *y; * 阅读全文
posted @ 2021-06-07 16:25 小鲨鱼2018 阅读(32) 评论(0) 推荐(0) 编辑
摘要: 1、 #include <stdio.h> #define NUMBER 5 void sort(int x[], int n) { int i, j; // i表示具体循环的轮数, j表示每一轮参与比较的元素的下标 for(i = 0; i < n - 1; i++)//一共循环的轮数n - 1, 阅读全文
posted @ 2021-06-07 09:57 小鲨鱼2018 阅读(814) 评论(0) 推荐(0) 编辑