#define MaxSize 50 //数组静态分配
typedef int ElemType;
typedef struct
{
ElemType data[MaxSize];
int length;
} SqList;
#define InitSize 50 //数组动态分配
typedef int ElemType;
typedef struct
{
ElemType *data;
int MaxSize, length;
} SqList;
typedef struct LNode //结点
{
ElemType data; //数据域
struct LNode *next; //指针域
} LNode, *LinkList;
s = (LNode *)malloc(sizeof(LNode));
s->data = x;
s->next = L->next;
L->next = s;
s = (LNode *)malloc(sizeof(LNode));
s->data = x;
r->next = s; //r为尾结点
r = s;