随笔分类 -  数据结构——单调栈

摘要:小于等于x且与x互素的数的和=phi(x)*x/2,(一定有phi(x)对数,可以找到一个t,和与其对应的一个x-t) 所以 f[i]=i, 1 #include <cstdio> 2 3 #define LL long long 4 inline void read(int &x) 5 { 6 x 阅读全文
posted @ 2017-10-19 15:28 Aptal丶 阅读(177) 评论(0) 推荐(0)
摘要:T1 财富(treasure) Time Limit:1000ms Memory Limit:128MB 题目描述 LYK有n个小伙伴。每个小伙伴有一个身高hi。 这个游戏是这样的,LYK生活的环境是以身高为美的环境,因此在这里的每个人都羡慕比自己身高高的人,而每个人都有一个属性ai表示它对身高的羡 阅读全文
posted @ 2017-10-09 20:37 Aptal丶 阅读(283) 评论(0) 推荐(0)
摘要:http://www.lydsy.com/JudgeOnline/problem.php?id=1012|| https://www.luogu.org/problem/show?pid=1198 Time Limit: 3 Sec Memory Limit: 162 MBSubmit: 10824 阅读全文
posted @ 2017-08-19 18:30 Aptal丶 阅读(262) 评论(0) 推荐(0)
摘要:http://acm.hdu.edu.cn/showproblem.php?pid=1506 || http://poj.org/problem?id=2559 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (J 阅读全文
posted @ 2017-08-18 20:10 Aptal丶 阅读(221) 评论(0) 推荐(0)
摘要:http://www.lydsy.com/JudgeOnline/problem.php?id=1113 Time Limit: 10 Sec Memory Limit: 162 MBSubmit: 1170 Solved: 792[Submit][Status][Discuss] Descript 阅读全文
posted @ 2017-08-18 19:22 Aptal丶 阅读(159) 评论(0) 推荐(0)
摘要:http://poj.org/problem?id=2796 Time Limit: 3000MS Memory Limit: 65536K Total Submissions: 15375 Accepted: 4252 Case Time Limit: 1000MS Special Judge h 阅读全文
posted @ 2017-08-18 17:57 Aptal丶 阅读(152) 评论(0) 推荐(0)
摘要:http://poj.org/problem?id=3250 Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 19619 Accepted: 6702 http://poj.org/problem?id=3250 Descript 阅读全文
posted @ 2017-08-18 15:04 Aptal丶 阅读(217) 评论(0) 推荐(0)