#ifndef _FUNC_H
#define _FUNC_H
#include <stdio.h>
#include <iostream>
#define OK 1
#define ERROR 0
#define MAX_VERTEX_NUM 20
#define INFINITY INT_MAX
typedef int Status;
typedef int VertexType;
typedef int VRType;
typedef int InfoType;
typedef enum {UDN} GraphKind;// 五向网
typedef struct ArcCell
{
VRType adj;
InfoType * info
}ArcCell, AdjMatrix[MAX_VERTEX_NUM][MAX_VERTEX_NUM];
typedef struct
{
VertextType vexs[MAX_VERTEX_NUM]; //顶点向量
AdjMatrix arcs; //领接矩阵
int vexnum, arcnum; //图的 当前节点和弧数
GraphKind kind; //图的种类
本内容试读结束,登录后可阅读更多
下载后可阅读完整内容,剩余3页未读,立即下载