上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 31 下一页

2016年3月3日

hdu 3518 Boring counting 后缀数组

摘要: 题目链接 根据height数组的性质分组计算。 #include <iostream> #include <vector> #include <cstdio> #include <cstring> #include <algorithm> #include <cmath> #include <map 阅读全文

posted @ 2016-03-03 16:35 yohaha 阅读(185) 评论(0) 推荐(0) 编辑

hdu 4628 Pieces 状压dp

摘要: 题目链接 枚举所有状态, 1表示这个字符还在原来的串中, 0表示已经取出来了。 代码中j = (j+1)|i的用处是枚举所有包含i状态的状态。 #include <iostream> #include <vector> #include <cstdio> #include <cstring> #in 阅读全文

posted @ 2016-03-03 13:37 yohaha 阅读(175) 评论(0) 推荐(0) 编辑

codeforces 633G. Yash And Trees dfs序+线段树+bitset

摘要: 题目链接 G. Yash And Trees time limit per test 4 seconds memory limit per test 512 megabytes input standard input output standard output Yash loves playin 阅读全文

posted @ 2016-03-03 10:57 yohaha 阅读(340) 评论(0) 推荐(0) 编辑

2016年3月2日

codeforces 630P. Area of a Star

摘要: 题目链接 圆上n个点等距离分布, 求构成的星星的面积。 我们可以求三角形OAB的面积, ∠CAE = 1/2 ∠ COE = PI/n, 那么∠CAO = PI/2n, ∠AOB非常好求, 就是PI/n, 然后AO = r, ∠ABO = PI-∠CAO-∠AOB, 就可以用正弦定理求出任意另外一条 阅读全文

posted @ 2016-03-02 20:47 yohaha 阅读(374) 评论(0) 推荐(0) 编辑

bzoj 2542: [Ctsc2001]终极情报网 费用流

摘要: 题目链接 2542: [Ctsc2001]终极情报网 Time Limit: 1 Sec Memory Limit: 128 MBSubmit: 321 Solved: 125[Submit][Status][Discuss] Description 在最后的诺曼底登陆战开始之前,盟军与德军的情报部 阅读全文

posted @ 2016-03-02 19:13 yohaha 阅读(403) 评论(0) 推荐(0) 编辑

codeforces 632E. Thief in a Shop fft

摘要: 题目链接 E. Thief in a Shop time limit per test 5 seconds memory limit per test 512 megabytes input standard input output standard output A thief made his 阅读全文

posted @ 2016-03-02 14:03 yohaha 阅读(361) 评论(0) 推荐(0) 编辑

hdu 1402 A * B Problem Plus fft

摘要: 题目链接 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 16382 Accepted Submission(s): 3325 阅读全文

posted @ 2016-03-02 13:05 yohaha 阅读(127) 评论(0) 推荐(0) 编辑

bzoj 1088: [SCOI2005]扫雷Mine

摘要: 题目链接 1088: [SCOI2005]扫雷Mine Time Limit: 10 Sec Memory Limit: 162 MBSubmit: 2525 Solved: 1495[Submit][Status][Discuss] Description 相信大家都玩过扫雷的游戏。那是在一个n* 阅读全文

posted @ 2016-03-02 10:48 yohaha 阅读(152) 评论(0) 推荐(0) 编辑

codeforces 632F. Magic Matrix

摘要: 题目链接 给一个n*n的矩阵, 问是否对角线上的元素全都为0, a[i][j]是否等于a[j][i], a[i][j]是否小于等于max(a[i][k], a[j][k]), k为任意值。 前两个都好搞, 我们来看第三个。 第三个的意思是, 对于a[i][j], 它小于等于第i行和第j行每一列的两个 阅读全文

posted @ 2016-03-02 09:14 yohaha 阅读(247) 评论(0) 推荐(0) 编辑

codeforces 632D. Longest Subsequence 筛法

摘要: 题目链接 记录小于等于m的数出现的次数, 然后从后往前筛, 具体看代码。 #include <iostream> #include <vector> #include <cstdio> #include <cstring> #include <algorithm> #include <cmath> 阅读全文

posted @ 2016-03-02 08:46 yohaha 阅读(271) 评论(0) 推荐(0) 编辑

上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 31 下一页

导航