基本操作有:
- 初始化顺序表
- 销毁顺序表
- 清空顺序表
- 插入一个元素
- 删除一个元素
- 获取某个位置的元素
- 顺序表中元素的定位
- 获取表长
- 判断表是否为空
- 有序合并两有序表
#include <bits/stdc++.h>
#define LIST_INIT_SIZE 100 // 初始容量
#define LISTINCREMENT 10 // 空间增量
#define OK 1
#define ERROR -1
#define OVERFLOW -1
using namespace std;
typedef int Status;
typedef int ElemType;
typedef struct SqList{
ElemType * elem; // 存储空间基址
in