📄 graph.h
字号:
// Graph.h: interface for the Graph class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_GRAPH_H__528E7B20_597A_11C7_83C2_0050FC21C815__INCLUDED_)
#define AFX_GRAPH_H__528E7B20_597A_11C7_83C2_0050FC21C815__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#define arcptr arcnode*
#define N_g 50
class Graph
{
struct arcnode{
int adjvex;
arcptr nextarc;
};
struct vexnode{
char vexdata;
arcptr firstarc;
};
vexnode adjlist[N_g];
public:
void outGraph();
int length;
void del_arc(char v,char w);
void del_vertex(char v);
void ins_arc(char v,char w);
void ins_vertex(char u);
char next_adj(char v,char w);
char first_adj(char v);
char get_vertex(int i);
int loc_vextex(char v);
Graph();
virtual ~Graph();
};
#endif // !defined(AFX_GRAPH_H__528E7B20_597A_11C7_83C2_0050FC21C815__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -