水题。

#pragma comment(linker, "/STACK:1024000000,1024000000")
#include<cstdio>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<vector>
#include<map>
#include<set>
#include<queue>
#include<stack>
#include<iostream>
using namespace std;
typedef long long LL;
const double pi=acos(-1.0),eps=1e-;
void File()
{
freopen("D:\\in.txt","r",stdin);
freopen("D:\\out.txt","w",stdout);
}
inline int read()
{
char c = getchar(); while(!isdigit(c)) c = getchar();
int x = ;
while(isdigit(c)) { x = x * + c - ''; c = getchar(); }
return x;
} int n,sum; int main()
{
scanf("%d",&n);
for(int i=;i<=n;i++)
{
int x; scanf("%d",&x);
sum=sum+x-;
if(sum%==) printf("2\n");
else printf("1\n");
}
return ;
}

CodeForces 705B Spider Man的更多相关文章

  1. 【模拟】Codeforces 705B Spider Man

    题目链接: http://codeforces.com/problemset/problem/705/B 题目大意: 两个人玩游戏,总共N个数,分别求前I(I=1 2 3...n)个数时游戏的获胜者是 ...

  2. CodeForces 705B Spider Man (水题)

    题意:给定 n 个数,表示不同的环,然后把环拆成全是1,每次只能拆成两个,问你有多少次. 析:也不难,反正都要变成1,所以把所有的数都减1,再求和即可. 代码如下: #pragma comment(l ...

  3. codeforces 705B B. Spider Man(组合游戏)

    题目链接: B. Spider Man time limit per test 2 seconds memory limit per test 256 megabytes input standard ...

  4. codeforces 705B:Spider Man

    Description Peter Parker wants to play a game with Dr. Octopus. The game is about cycles. Cycle is a ...

  5. CodeForces 705B (训练水题)

    题目链接:http://codeforces.com/problemset/problem/705/B 题意略解: 两个人玩游戏,解数字,一个数字可以被分成两个不同或相同的数字 (3可以解成 1 2) ...

  6. Codeforces 216D Spider&#39;s Web 树状数组+模拟

    题目链接:http://codeforces.com/problemset/problem/216/D 题意: 对于一个梯形区域,假设梯形左边的点数!=梯形右边的点数,那么这个梯形为红色.否则为绿色, ...

  7. ACM 博弈(难)题练习 (第一弹)

    第二弹: 套路&&经验总结: 1. N堆***的游戏,一般可以打表找SG函数的规律.比如CodeForces 603C 2.看起来是单轮的游戏,实际上可能拆分成一些独立的子游戏.比如C ...

  8. Codeforces Gym 100523K K - Cross Spider 计算几何,判断是否n点共面

    K - Cross SpiderTime Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.hust.edu.cn/vjudge/contest/v ...

  9. Codeforces Round #366 (Div. 2)_B. Spider Man

    B. Spider Man time limit per test 2 seconds memory limit per test 256 megabytes input standard input ...

随机推荐

  1. 转载 C#文件上传

     一.分析 本次博客,主要解决文件上传等一系列问题,将从两方面来论述,即1G以内文件和1G以上文件. 对于上传1G以内的文件,可以采用基本的三种上传方法:用Web控件FileUpload.html控件 ...

  2. Java 集合:HashSet 与 ArrayList

    Set 集合是无序不可以重复的的.List 集合是有序可以重复的. Java 集合:HashSet 与 hashCode.equals 博客里面已经说到这个问题,但是解释的还是不够清楚. 看一个小例子 ...

  3. Hibernate3 第二天

    Hibernate3 第二天 第一天回顾: 三个准备 创建数据库 准备po和hbm文件 准备灵魂文件hibernate.cfg.xml 七个步骤 1 加载配置文件Configuration 2 创建会 ...

  4. Raspberry Pi(树莓派)上从零开始构建Linux系统(简称PiLFS)(一)

    一. 准备工作 1. 装有Linux宿主系统的树莓派主板,可参考 Raspberry Pi(树莓派)上安装Raspbian(无路由器,无显示器) 2. 参考网址:Linux From Scratch ...

  5. selenium自动化过程中遇到的小问题(未完待续)

    1.chrome浏览器调用不起来 代码没出错的情况下,检查下chrome浏览器的版本与chromedriver.exe的版本是否匹配;下面的表格是根据网上及官网整理的chromedriver与chro ...

  6. CSS多列、用户界面属性

    CSS多列 常用属性: column-count 分几列 column-gap 列间距 column-rule 列分割线的样式(写法和border一样) 例如: 一个div分三列,列之间间距为10px ...

  7. Access一些常用的SQL语句

    您可以将 Microsoft Office Access 2013 用作创建.修改数据库以及处理数据的工具,还可将 Office Access 2013 用作服务器数据库管理系统(如 Microsof ...

  8. freemarker 遍历 hashmap 到select option

    <select id="experience"> <option value ="">--请选择--</option> &l ...

  9. 数据库开启gtid时,需要注意的问题

    1.slave不能执行任何sql,包括超级用户2.read_only=on,这个必须要开启,避免业务执行sql3.保证当前slave的事务id为1 当slave同步出现问题时,手动跳过,需要考虑的问题 ...

  10. 移动APP脚本录制

    1.安装补丁--LR_03105_patch4----mobile app(http/html) 2.录制软件和移动设备同处同一环境(160wifi连接移动设备),创建wifi热点 3.创建脚本-协议 ...