⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 seqlist.h

📁 数据结构中的二叉树的遍历(前序、中序、后序)算法
💻 H
字号:
/*
  Name: seqList.h
  Copyright: jnu@math
  Author: Fan zz (arcst1715@gmail.com)
  Date: 29-09-08 16:39
  Description:sequential list
*/
#include "status.h"

#define ElemType int
//线性表的动态分配顺序存储结构定义
#define LIST_INIT_SIZE 100          //Initial size of seq_list
#define LISTINCREMENT   10          //Incremental size of seq_list

typedef struct {
	ElemType * elem;            //the base address
	int     length;             //used size
	int     listsize;           //size of list(sizeof(ElemType);
}SqList;

Status InitList_Sq(SqList &L);
Status ListInsert_Sq(SqList &L, int i, ElemType e);
Status ListAppend_Sq(SqList &L, ElemType e);
Status ListDelete_Sq(SqList &L, int i, ElemType& e);
void MergeList_Sq(SqList La, SqList Lb, SqList &Lc);
int LocateElem_Sq(SqList L, ElemType e,Status (*compare)(ElemType, ElemType));
void PrintList_Sq(SqList La);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -