上一页 1 2 3 4 5 6 7 8 9 ··· 31 下一页
摘要: bzoj1337 洛谷P1742 用随机增量法。讲解:https://blog.csdn.net/jokerwyt/article/details/79221345 设点集A的最小覆盖圆为g(A)可以发现:1.g(A)是唯一的2.g(A)可以由<=3个点唯一确定①由一个点确定(所有点重合时)②由两个 阅读全文
posted @ 2018-10-24 15:23 hehe_54321 阅读(160) 评论(0) 推荐(0) 编辑
摘要: https://konnyakuxzy.github.io/BZPRO/JudgeOnline/2740.html 题解讲的很清楚了 (好像等于的情况应该归入case2而不是case1?并不确定) 具体方法: 将串翻转,找到字典序最小且最短的后缀,然后找到以这个后缀为纯循环节的最长后缀T,则第一步是 阅读全文
posted @ 2018-10-24 10:03 hehe_54321 阅读(234) 评论(0) 推荐(0) 编辑
摘要: https://www.lydsy.com/JudgeOnline/problem.php?id=5449 话说很早以前做过。。算是IDA*的板子吧,一个简单的估价函数就可以过去了 1 %:pragma GCC optimize(2) 2 #include<cstdio> 3 #include<al 阅读全文
posted @ 2018-10-23 21:31 hehe_54321 阅读(315) 评论(0) 推荐(0) 编辑
摘要: vim 1.多行注释 (以下方法可以在多行的每一行前面加入相同内容) Ctrl-v进入visual block模式;调整选择块;按I(大写的i);输入要加的字符;按esc,等待几秒 2.多行缩进 ①用多行注释相同方法 ②可视模式下按shift+<(减少缩进)或者shift+>(增加缩进) ③:l,r 阅读全文
posted @ 2018-10-23 20:11 hehe_54321 阅读(408) 评论(0) 推荐(0) 编辑
摘要: https://codeforces.com/problemset/problem/455/D 其实方法很多,然而当初一个也想不到... 1.分块,块内用链表维护 修改[l,r]就当成删除第r个元素,在第l个元素之前插入删掉的元素:就找到r删除,然后调整各个块的结构(对于[block[l]+1,bl 阅读全文
posted @ 2018-10-23 19:42 hehe_54321 阅读(388) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2018-10-23 17:57 hehe_54321 阅读(3) 评论(0) 推荐(0) 编辑
摘要: https://codeforces.com/problemset/problem/407/C (自用,勿看) 手模一下找一找规律,可以发现,对于一个修改(l,r,k),相当于在[l,r]内各位分别加上[1,0,0,0,0,..]做k+1次前缀和得到的数组 比如(l=3,r=6,k=2),[1,0, 阅读全文
posted @ 2018-10-23 15:38 hehe_54321 阅读(211) 评论(0) 推荐(0) 编辑
摘要: https://codeforces.com/contest/650/problem/D 原题? http://210.33.19.103/contest/1024/problem/2 4s 520M 题解很明白了: 当初想错了,想用stormwind的做法去做,发现要维护 给出数组a,f,gj<i 阅读全文
posted @ 2018-10-23 08:03 hehe_54321 阅读(195) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2018-10-22 19:07 hehe_54321 阅读(4) 评论(0) 推荐(0) 编辑
摘要: https://www.luogu.org/problemnew/show/P3957 错误记录:1.没开longlong 2. -inf不够小 1 #include<cstdio> 2 #include<algorithm> 3 #include<cstring> 4 #include<vecto 阅读全文
posted @ 2018-10-20 15:17 hehe_54321 阅读(148) 评论(0) 推荐(0) 编辑
摘要: https://www.lydsy.com/JudgeOnline/problem.php?id=4597 https://www.luogu.org/problemnew/show/P4340 妄图直接暴力维护一堆东西,以直接维护题目要求的值(具体见代码...) 最后花了2个小时维护完了,A掉了, 阅读全文
posted @ 2018-10-19 20:25 hehe_54321 阅读(140) 评论(0) 推荐(0) 编辑
摘要: https://www.luogu.org/problemnew/show/P2376 看了题解做的,根本不会贪心。。 1 #include<cstdio> 2 #include<algorithm> 3 #include<cstring> 4 #include<vector> 5 using na 阅读全文
posted @ 2018-10-19 16:17 hehe_54321 阅读(189) 评论(0) 推荐(0) 编辑
摘要: https://www.lydsy.com/JudgeOnline/problem.php?id=4318 https://www.luogu.org/problemnew/show/P1654 看来自己还是naive... 注意:和的期望=期望的和;平方的期望!=期望的平方,立方的期望!=期望的立 阅读全文
posted @ 2018-10-18 15:04 hehe_54321 阅读(114) 评论(0) 推荐(0) 编辑
摘要: https://codeforces.com/contest/487/problem/E http://uoj.ac/problem/30 显然割点走过去就走不回来了...可以看出题目跟点双有关 有一个结论:如果在点双中有不同的点a,b,c,那么一定存在点不重复的路径从a到c再到b。 证明(摘自ht 阅读全文
posted @ 2018-10-17 22:27 hehe_54321 阅读(196) 评论(0) 推荐(0) 编辑
摘要: https://www.lydsy.com/JudgeOnline/problem.php?id=1791 基环树模板题 原来的代码:(本机AC) 1 #include<cstdio> 2 #include<algorithm> 3 #include<cstring> 4 #include<vect 阅读全文
posted @ 2018-10-17 09:18 hehe_54321 阅读(159) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 31 下一页
AmazingCounters.com