
cf
文章平均质量分 81
Hadis_yuki
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Codeforces Round #192 (Div. 2)
A. Cakeminator time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You are given a rectangular cake, represented as an r ×原创 2013-07-25 21:57:31 · 1291 阅读 · 0 评论 -
Codeforces Round #199 (Div. 2) A ( 简单贪心 )
题目链接:点击打开链接 先让我痛哭一下,居然跪在了水题上。。。。还是道水的贪心。。。。T^T。。。 找规律找规律。。。。cf都是思维题,记住了!!!! 大牛请自动跳过这篇博客,我是写给自己看的。。。。血的教训。。。 多么痛的领悟。。。。 分析: 只可能是三种组合 : 1 2 4 / 1 2 6 / 1 3 6 先判断除了1 2 3 4 6外还有没有别的原创 2013-09-07 23:27:40 · 699 阅读 · 0 评论 -
Round #203 (Div. 2) A------TL
1、题目链接:点击打开链接 2、模拟可过,在100以内枚举也可过。 3、昨天居然考虑错了。。。。。被HACK。。。。 我开始写的是 :找正确解法中的最大值max1和最小值min1,找错误解法中的最小值min2。 if (max1> 2*min1 || min2 显然错了啊,max1是可以大于2*原创 2013-10-02 09:18:31 · 1038 阅读 · 0 评论 -
Round #203 (Div. 2)B------Resort
思路:把出度大于1的点去掉,以每一个hotel为起点搜索找最长路径。 链接:点击打开链接 #include #include #include using namespace std; int len,fa[100010],sum[100010],maxpath,hotel[100010]; int dfs(int x) { if(fa[x]==0) r原创 2013-10-02 10:37:01 · 885 阅读 · 0 评论 -
Codeforces Round #203 (Div. 2) C------Bombs
1、只需要按距离原点的远近排序然后按照规则输出就可以了。昨天居然没看这么水的题= =! 2、不过代码写得有点丑。。哎。。。 #include #include #include #include #include using namespace std; struct node { int x,y; int step; }t[100010]; bool cmp(原创 2013-10-02 16:58:22 · 818 阅读 · 0 评论 -
cf Round #202 (div.2) C ------------ Mafia
只是觉得这个题用二分枚举过真是太神了。。。还是发下 思路:在最小可能round数(玩家想玩的最大盘数)和最大可能round数(所有玩家想玩盘数的总和) 范围内二分枚举得到最少需要玩的盘数。 只要满足所有玩家不玩的盘数>=当前盘数 && 当前盘数>=玩家想玩的最大盘数。 #include #include #in原创 2013-10-03 13:35:49 · 879 阅读 · 0 评论 -
Codeforces Round #205 (Div. 2) B. Two Heaps
题意:要把2*n个两位数分成两堆,使得第一堆上的和第二堆上的两个两位数组成四位数。 求怎么分能使构成的不同的四位数个数最多。 分析:如果是2*n个不同的,每堆分n个,最多能组成 n*n个不同的四位数。 但是如果有相同的二位数,那么: 1、相同的两位数重复个数为2,则分在不同堆上构成的四位数多。原创 2013-10-12 19:50:38 · 989 阅读 · 0 评论 -
Codeforces Round #208 (Div. 2) A_ Dima and Continuous Line
点都在一条直线上。输入点的横坐标。 输入中相邻两点间有半圆弧。(输入时不按坐标大小而是坐标乱序) 判断两点间构成的半圆弧是否相交。 假设n个点中 x1 和 x2之间有半圆弧,x3 和 x4 之间有半圆弧。 则当满足 程序注释中8种情况时相交。 时间复杂度为O(N*N) #include #include #include #include #include #i原创 2013-10-26 07:40:07 · 1301 阅读 · 2 评论