![](https://img-blog.csdnimg.cn/20201014180756923.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
拓扑
河渔船
成长的小垃圾
展开
-
例4.15 奖金(拓扑排序)
#include<iostream> #include<cstdio> #include<cstring> #include<string> #include<algorithm> int n,m; int f[10001]; int tree[10001][301]; int r[10001],ans=0; using namespace std; int main() { scanf(原创 2017-02-09 16:07:44 · 591 阅读 · 0 评论 -
摄像头
https://www.luogu.org/problem/show?pid=2712 拓扑排序嘛。每次找入度为零即没有被观测的摄像头砸掉,再把它所观测的摄像头的入度-1. 不过此题有一个特别坑的地方,就是摄像头的编号并不是1~n。#include<iostream> #include<cstring> #include<string> #include<algorithm> #includ原创 2017-07-27 16:07:52 · 240 阅读 · 0 评论 -
烦人的幻灯片
Page 527#include<iostream> #include<cstdio> #include<cstring> #include<string> #include<algorithm> using namespace std; int n; struct H{ int x1,x2,y1,y2; }card[30]; struct K{ int x,y; }f[30];原创 2017-02-10 08:21:09 · 1316 阅读 · 0 评论