堆
WatchLessMobile
这个作者很懒,什么都没留下…
展开
-
1147 Heaps (30分)
#include <iostream>#include <algorithm>#include <vector>using namespace std;const int SIZE = 10010;const int INF = 99999999;int heap[SIZE];int M, N;bool cmp(const int& a, const int& b) { return a > b;}void post原创 2020-11-23 19:14:07 · 99 阅读 · 0 评论 -
1155 Heap Paths (30分)
#include <algorithm>#include <vector>#include <iostream>using namespace std;const int SIZE = 1005;int N;int heap[SIZE];bool visit[SIZE] = {false};vector<int> path;bool flagMAX = true;bool flagMIN = true;bool cmpMAX(co原创 2020-11-23 19:13:17 · 48 阅读 · 0 评论