摘要: 运行结果: 代码如下: #include<stdio.h> //数组初始化函数 void Array_get(int array[],int max) { printf("请输入一个数组,大小从低到高,各个数字间以空格隔开:"); for (size_t i = 0; i < max; i++) { 阅读全文
posted @ 2020-07-28 18:21 骑码的佳俊 阅读(628) 评论(0) 推荐(0) 编辑
摘要: 建立上图的一个txt文件: 1004 TOM 1001002 lily 951001 ann 931003 lucy 98 用一个c程序读入这个表一个结构体数组中: 结构体如下: //学生数据结构体 typedef struct student { int id; //学号 char name[10 阅读全文
posted @ 2020-07-28 17:34 骑码的佳俊 阅读(790) 评论(0) 推荐(0) 编辑
摘要: 邻接表储存结构 /*邻接表的边*/ typedef struct ArcNode { int adjvex; struct ArcNode *next; }ArcNode; /*邻接表的结点*/ typedef struct VNode { char date; ArcNode *firstarc; 阅读全文
posted @ 2020-07-28 15:10 骑码的佳俊 阅读(620) 评论(0) 推荐(1) 编辑