![](https://img-blog.csdnimg.cn/20201014180756918.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C/C++
文章平均质量分 71
xiaogmail
学c中
展开
-
fookwood的简单vector实现
#include #include template class Vector{ private: int theSize; //the elements it contains int theCapacity; Object *objects; public: explicit Vector( int initSize = 0 ):转载 2013-05-27 17:10:56 · 382 阅读 · 0 评论 -
拓扑排序
/* 输入边,建立邻接表,出边表; 拓扑排序:找出入度为零的顶点,删除之,及其出边, 更新相邻顶点入度; 重复上过程,直到栈为空(栈用来保存度为零的顶点) 或待输出顶点数小于输入顶点,有环。 */ #include #include using namespace std; const int MAXN=10; int n,m; int OUT[MAXN]; //o原创 2013-05-27 17:41:10 · 382 阅读 · 0 评论