10 2019 档案

摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=1533 相邻的容量为inf,费用为1,S到m容量为1,费用为0 ,H到T容量为1,费用为0。 建图跑-最小费用最大流-就行了。 阅读全文
posted @ 2019-10-31 21:34 ZMWLxh 阅读(178) 评论(0) 推荐(0) 编辑
摘要:题意: Philosopher’s Walk 图,告诉你step返回位置。 思路: 按四个块DFS 阅读全文
posted @ 2019-10-31 10:36 ZMWLxh 阅读(206) 评论(0) 推荐(0) 编辑
摘要:题意:https://blog.csdn.net/Ratina/article/details/95200594 思路: 首先我们知道最小生成树就是按长度枚举边,能连就连。 那么,如果这条边在最小生成树里,那我们只需要看比它短的边是不是已经使当前的u v连通,如果连通最少需要切掉几条(边权为1跑最小 阅读全文
posted @ 2019-10-31 10:21 ZMWLxh 阅读(271) 评论(0) 推荐(0) 编辑
摘要:题意:https://www.luogu.org/problem/P2756 阅读全文
posted @ 2019-10-28 20:18 ZMWLxh 阅读(262) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=5980 b乘以GCD(a,b)之后,解方程就行了。 阅读全文
posted @ 2019-10-26 21:31 ZMWLxh 阅读(303) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=5971 把已经告诉你的把能推测的都推测出来有矛盾就“NO”,剩下的跑二分图,矛盾就“NO”,剩下如果还有没有颜色的“NO”。 阅读全文
posted @ 2019-10-26 21:29 ZMWLxh 阅读(177) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=5976 首先队友想出了分的越多答案越多。 我们就:2,3,4,5,6.。。多出来的尽量往小了加就行了。 阅读全文
posted @ 2019-10-26 21:26 ZMWLxh 阅读(252) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=5973 根号5复制后200位就行了,因为BigDecimal不支持开根号,除法二分开根。 阅读全文
posted @ 2019-10-26 21:22 ZMWLxh 阅读(209) 评论(0) 推荐(0) 编辑
摘要:1 #define IOS ios_base::sync_with_stdio(0); cin.tie(0); 2 #include <cstdio>//sprintf islower isupper 3 #include <cstdlib>//malloc exit strcat itoa system("cls") 4 #include <iostream>//pair 5 #include 阅读全文
posted @ 2019-10-26 09:41 ZMWLxh 阅读(173) 评论(0) 推荐(0) 编辑
摘要:题意:http://codeforces.com/problemset/problem/1096/D 思路:参考:https://blog.csdn.net/qq_41289920/article/details/100715683 阅读全文
posted @ 2019-10-24 21:57 ZMWLxh 阅读(164) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=1565 取不相邻的点是权值最大。 这题可以网络流做,暂时先DP一下,网络流明天学一下~~ 阅读全文
posted @ 2019-10-22 22:21 ZMWLxh 阅读(231) 评论(0) 推荐(0) 编辑
摘要:题意:http://acm.hdu.edu.cn/showproblem.php?pid=1540 写了我老久 阅读全文
posted @ 2019-10-21 16:04 ZMWLxh 阅读(191) 评论(0) 推荐(0) 编辑
摘要:题意:https://vjudge.net/contest/336100#problem/B HDU6231 阅读全文
posted @ 2019-10-20 10:56 ZMWLxh 阅读(226) 评论(0) 推荐(0) 编辑
摘要:题意:https://www.luogu.org/problem/P3919 阅读全文
posted @ 2019-10-19 13:14 ZMWLxh 阅读(166) 评论(0) 推荐(0) 编辑
摘要:题意:https://www.nitacm.com/problem_show.php?pid=1470 阅读全文
posted @ 2019-10-17 21:49 ZMWLxh 阅读(272) 评论(0) 推荐(0) 编辑
摘要:题意:https://www.nitacm.com/problem_show.php?pid=1378 如题。 思路: 从第一行for到最后一行,枚举每一行的所有状态,进行转移,注意答案是dp【最后一行】【0】,因为最后一行是唯一确定的。 https://blog.csdn.net/Tc_To_To 阅读全文
posted @ 2019-10-16 22:23 ZMWLxh 阅读(341) 评论(0) 推荐(0) 编辑
摘要:题意:https://ac.nowcoder.com/acm/contest/1111/D 问你先减二x次的情况下,最少减几次3。 思路: %3不为0的要先减2,然后%3为0的要先减大的(比如9 3 3 会比3 3 9 更优) 阅读全文
posted @ 2019-10-08 21:44 ZMWLxh 阅读(245) 评论(0) 推荐(0) 编辑
摘要:题意:https://ac.nowcoder.com/acm/contest/1109/C 问你有几个x满足A,B集合都能XOR出x。 思路: 就是线性基求交后,有几个基就是2^几次方。 阅读全文
posted @ 2019-10-04 19:05 ZMWLxh 阅读(264) 评论(0) 推荐(0) 编辑
摘要:题意:https://ac.nowcoder.com/acm/contest/881/I 给你n个平面上的点,每个点有a、b两个权值,现在让你划分成两个区域(要求所有A集合里的点不能在任何B集合里的点的右下方)。 求MAX(Sigma ai+Sigma bi)。 思路: dp+线段树。 https: 阅读全文
posted @ 2019-10-04 10:52 ZMWLxh 阅读(280) 评论(0) 推荐(0) 编辑
摘要:题意:https://codeforces.com/group/ikIh7rsWAl/contest/254825/problem/E 给你一个n,计算n / Sigma(1~n)的d(是n的只出现一次的因数)。 思路: 反正就是打表找规律,3组数据也能找规律,你们是真的nb嗷。 阅读全文
posted @ 2019-10-03 19:11 ZMWLxh 阅读(417) 评论(0) 推荐(0) 编辑
摘要:题意:https://ac.nowcoder.com/acm/contest/1107/J n个点的完全图编号0-n-1,第i个点的权值为2^i,原先是先手选取一些边,然后后手选取一些点,满足先手选取的所有边对应的两点至少要有一个,并且总的权值和最少,现在给你后手选取的点得权值和,求先手选取边的方案 阅读全文
posted @ 2019-10-02 20:06 ZMWLxh 阅读(281) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示