摘要:
题目 不能多想系列,手玩几组数据简略证明出最终序列也只会存在$0,1, 1$三个数 做法 这样就好做了嘛 $dp[i][c]$表示前$i$个数,第$i$个数最终变成$c$,然后枚举前一个数转移就好 My complete code cpp include using namespace std; t 阅读全文
摘要:
题目 [ZJOI2010]网络扩容 $A:$报告,发现一道水题 $B:$切掉切掉 做法 考虑做第二问,$u\frac{~~f~~}{~~0~~}v,u\frac{~~K~~}{~~c~~}v$,然后跑最大流最小费用就好了 My complete code cpp include using name 阅读全文
摘要:
题目 "洛谷" 做法 考虑最多能删的点 $S$向每行所代表的点连(该行最多能删的点)容量的边,每列向$T$连(同理)的边 每个存在的格子$(x,y)$,$x$向$y$连$1$容量的边 My complete code cpp include include using namespace std; 阅读全文