- 2
- 0
- 约1.31万字
- 约 64页
- 2017-02-06 发布于天津
- 举报
第五章数组广义表-数据结构
例如: ? a (x, y) ((x)) LS=( a, (x,y), ((x)) ) ls 5.5 广义表的存储结构 广义表的头尾链表存储表示 typedef enum{ATOM,LIST} ElemTag; typedef struct GLNode{ ElemTag tag; union{ AtomType atom; struct GLNode *hp; }; struct GLNode *tp; } 5.5 广义表的存储结构 * cpot[1] = 1; // 求 M 中每一列的第一个非零元在 b.data 中的序号 for (col=2; col=M.nu; ++col) cpot[col] = cpot[col-1]+num[col-1]; for (p=1; p=M.tu; ++p) { col = M.data[p].j; q = cpot[col]; T.data[q].i =M.data[p].j; T.data[q].j =M.data[p].i; T.data[q].e =M.data[p].e; ++cpot[col]; }
原创力文档

文档评论(0)