AC日记——Little Elephant and Function codeforces 221a
A - Little Elephant and Function
思路:
水题;
代码:
#include <cstdio>
#include <iostream> using namespace std; int n; int main()
{
scanf("%d",&n);
printf("%d ",n);
for(int i=;i<n;i++) printf("%d ",i);
return ;
}
AC日记——Little Elephant and Function codeforces 221a的更多相关文章
- AC日记——Little Elephant and Shifts codeforces 221e
E - Little Elephant and Shifts 思路: 一次函数线段树(疯狂debug): b不断循环左移,判断每次最小的|i-j|,a[i]=b[j]: 仔细观察发现,每个bi移动时, ...
- AC日记——Little Elephant and Array codeforces 221d
221D - Little Elephant and Array 思路: 莫队: 代码: #include <cmath> #include <cstdio> #include ...
- AC日记——Little Elephant and Numbers codeforces 221b
221B - Little Elephant and Numbers 思路: 水题: 代码: #include <cmath> #include <cstdio> #inclu ...
- AC日记——Little Elephant and Problem codeforces 221c
221C 思路: 水题: 代码: #include <cstdio> #include <cstring> #include <iostream> #include ...
- AC日记——Sagheer and Nubian Market codeforces 812c
C - Sagheer and Nubian Market 思路: 二分: 代码: #include <bits/stdc++.h> using namespace std; #defin ...
- AC日记——Red and Blue Balls codeforces 399b
399B - Red and Blue Balls 思路: 惊讶的发现,所有的蓝球的消除都是独立的: 对于在栈中深度为i的蓝球消除需要2^i次操作: 代码: #include <cstdio&g ...
- AC日记——Andryusha and Colored Balloons codeforces 780c
C - Andryusha and Colored Balloons 思路: 水题: 代码: #include <cstdio> #include <cstring> #inc ...
- AC日记——The Child and Sequence codeforces 250D
D - The Child and Sequence 思路: 因为有区间取模操作所以没法用标记下传: 我们发现,当一个数小于要取模的值时就可以放弃: 凭借这个来减少更新线段树的次数: 来,上代码: # ...
- Codeforces 221 A. Little Elephant and Function
A. Little Elephant and Function time limit per test 2 seconds memory limit per test 256 megabytes in ...
随机推荐
- laravel5.5事件广播系统
目录 1. 定义广播事件 1.1 广播名称 1.2 广播数据 1.3 广播队列 1.4 广播条件 2. 频道授权 2.1 定义授权路由 2.2 定义授权回调 3. 对事件进行广播 3.1 可以使用ev ...
- 【java下午茶系列】java三重奏之封装
java中的封装.继承.多态可谓是踏入这一行业的必经之槛,诸多新人在不明就里的情况下将其各种概念背的是滚瓜烂熟.即便是工作多年之后,也不见得能说出个所以然,或许冥冥之中已经写过无数封装的代码,只是 ...
- 操作App.config的类(转载)
http://www.cnblogs.com/yaojiji/archive/2007/12/17/1003191.html 操作App.config的类 public class DoConfig ...
- Python3基本语法
#编码 ''' 默认情况下,Python 3 源码文件以 UTF-8 编码,所有字符串都是 unicode 字符串. 当然你也可以为源码文件指定不同的编码: # -*- coding: cp-1252 ...
- FOJ Problem 1015 土地划分
Problem 1015 土地划分 Accept: 823 Submit: 1956Time Limit: 1000 mSec Memory Limit : 32768 KB Probl ...
- Extjs 4 小记
////////////////////////////////////---Ajax 等待提示消息---/////////////////////////////////////////////// ...
- Linux命令 -文件操作类
声明:本文所涉及到的Linux命令均为最常见的用法,未列举之参数,自行查阅man 1.ls 查看文件与目录 -a 打印全部的文件,包括隐藏文件 -l 列表打印,数据项包括文件属性,大小和权限等 ...
- LeetCode -- Implement Stacks using Queue
Question: Implement the following operations of a queue using stacks. push(x) -- Push element x to t ...
- GYM - 101147 K.Touristic Trip
题意: 一个人从城市0开始旅行.一共有N座城市,他每到一座城市都会寄一张明信片.给出从一座城市到另一座城市的概率和在每座城市寄出每张明信片的概率.给出长度为k的寄明信片的序列.问在该序列的条件下在第Z ...
- 快来看看Google出品的Protocol Buffer,别只会用Json和XML了
前言 习惯用 Json.XML 数据存储格式的你们,相信大多都没听过Protocol Buffer Protocol Buffer 其实 是 Google出品的一种轻量 & 高效的结构化数据存 ...