Codeforces Round #124 (Div. 2)
A. Plate Game
- 如果可以放置一个圆的情况下,先手将圆放置在矩形正中心,那么根据对称性,先手只要放后手的对称的位置即可,也就是先手必胜,否则后手胜。
B. Limit
- 讨论\(n,m\)的大小关系。
- 虚拟场时当\(n \gt m\)的情况写错了,应该根据\(a_0b_0\)的正负性判断是正无穷还是负无穷。
C. Lexicographically Maximum Subsequence
- 从后往前扫,递增的取。
D. Infinite Maze
- 假设原地图为\(M\),则扩展成\[MM\\MM\]
- 从\(S\)开始遍历扩展地图,如果能走到\[(S_x + n, S_y)、(S_x, S_y + m)、(S_x + n, S_y + m)\]其中一个位置,显然能无限走下去。
E. Paint Tree
- 注意题目保证任意三点不共线。
- 可以每次取左下角的点做当前顶点,其余点极角排序下,顺序扫过去,每次取子树大小的点数,则化为一个新的子问题,递归求解即可。
Codeforces Round #124 (Div. 2)的更多相关文章
- Codeforces Round #124 (Div. 1) C. Paint Tree(极角排序)
C. Paint Tree time limit per test 2 seconds memory limit per test 256 megabytes input standard input ...
- Codeforces Round #366 (Div. 2) ABC
Codeforces Round #366 (Div. 2) A I hate that I love that I hate it水题 #I hate that I love that I hate ...
- Codeforces Round #354 (Div. 2) ABCD
Codeforces Round #354 (Div. 2) Problems # Name A Nicholas and Permutation standard input/out ...
- Codeforces Round #368 (Div. 2)
直达–>Codeforces Round #368 (Div. 2) A Brain’s Photos 给你一个NxM的矩阵,一个字母代表一种颜色,如果有”C”,”M”,”Y”三种中任意一种就输 ...
- cf之路,1,Codeforces Round #345 (Div. 2)
cf之路,1,Codeforces Round #345 (Div. 2) ps:昨天第一次参加cf比赛,比赛之前为了熟悉下cf比赛题目的难度.所以做了round#345连试试水的深浅..... ...
- Codeforces Round #279 (Div. 2) ABCDE
Codeforces Round #279 (Div. 2) 做得我都变绿了! Problems # Name A Team Olympiad standard input/outpu ...
- Codeforces Round #262 (Div. 2) 1003
Codeforces Round #262 (Div. 2) 1003 C. Present time limit per test 2 seconds memory limit per test 2 ...
- Codeforces Round #262 (Div. 2) 1004
Codeforces Round #262 (Div. 2) 1004 D. Little Victor and Set time limit per test 1 second memory lim ...
- Codeforces Round #371 (Div. 1)
A: 题目大意: 在一个multiset中要求支持3种操作: 1.增加一个数 2.删去一个数 3.给出一个01序列,问multiset中有多少这样的数,把它的十进制表示中的奇数改成1,偶数改成0后和给 ...
随机推荐
- 对项目的测试--Resharper
初学 这里做个记录. 1:安装后,Resharper会用他自己的英文智能提示,替换掉 vs2010的智能提示,所以我们要换回到vs2010的智能提示 2:快捷键.是使用vs2010的快捷键还是使用 R ...
- 【转发】linux yum命令详解
linux yum命令详解 yum(全 称为 Yellow dog Updater, Modified)是一个在Fedora和RedHat以及SUSE中的Shell前端软件包管理器.基於RPM包管理, ...
- iphone获取当前流量信息
通过读取系统网络接口信息,获取当前iphone设备的流量相关信息,统计的是上次开机至今的流量信息. 代码 悦德财富:https://yuedecaifu.com 1 2 3 4 5 6 7 8 9 1 ...
- iOS 使用两个tableview的瀑布流
代码 悦德财富:https://www.yuedecaifu.com 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 ...
- win8系统 host文件无法修改解决之道
host文件,路径为:C:\windows\system32\drivers\etc\hosts 方法/步骤: 方法1:用notepad++打开host文件,修改和保存 方法2:(1)首先用管理管权限 ...
- Navicat提示Access violation at address 004E9844 in module ‘navicat.exe’
今天在联系MySQL 数据库表的练习时,出现了一下问题: 内存越界问题,最好重新注册下Windows的动态链接库 首先“开始”—“运行”—“cmd” 在打开的dos窗口中运行“for %1 in (% ...
- 《JAVA笔记 day08 静态_单例》
//static关键字: /* 静态方法的使用注意事项: 1,静态方法不能访问非静态的成员. 但是非静态是可以访问静态成员的. 说明:静态的弊端在于访问出现了局限性.好处是可以直接别类名调用. 2,静 ...
- mysql innoDB 与 myISAM
转载文章 出处 http://www.pureweber.com/article/myisam-vs-innodb/ 使用MySQL当然会接触到MySQL的存储引擎,在新建数据库和新建数据表的时候都 ...
- 安装VMware Tools找不到内核头文件
http://blog.csdn.net/bobbat/article/details/38568885 安装VMware Tools,解决无法找到kernel header path的问题 安装 V ...
- Python OpenCV ——Matplotlib显示图片
Color image loaded by OpenCV is in BGR mode.But Matplotlib displays in RGB mode.So color images will ...