图论:拓扑排序
文章平均质量分 70
skajre
这个作者很懒,什么都没留下…
展开
-
图 邻接链表的拓扑排序
#include #include using namespace std; #define MAX 10 typedef char Elemtype; typedef struct link{ int num; struct link *next; }slink; typedef struct{ struct{ Elemtype vertex;原创 2016-05-11 20:29:49 · 614 阅读 · 0 评论 -
UVA 1423 Guess(拓扑排序)
#include #include #include #include using namespace std; const int maxn=10+5; int degree[maxn],map[maxn][maxn],b[maxn],ans[maxn]; char s[maxn]; int n; void topo() { int vis[maxn]; int count=0,原创 2016-11-12 19:27:35 · 250 阅读 · 0 评论