题目链接: http://codeforces.com/contest/435/problem/D D. Special Grid time limit per test:4 secondsmemory limit per test:256 megabytes 问题描述 You are given an n × m grid, some of its nodes are black, the others are white. Moreover, it's not an ordinary gri…
题目地址:http://codeforces.com/contest/435/problem/C /* 题意:给一组公式,一组数据,计算得到一系列的坐标点,画出折线图:) 模拟题:蛮恶心的,不过也简单,依据公式得知折线一定是一上一下的,只要把两个相邻的坐标之间的折线填充就好 注意:坐标有可能为负数,所以移动值y初始化为1000,最后要倒过来输出 详细解释:http://blog.csdn.net/zhb1997/article/details/27877783 */ #include <cstd…
题目传送门 /* 构造:从大到小构造,每一次都把最后不是9的变为9,p - p MOD 10^k - 1,直到小于最小值. 另外,最多len-1次循环 */ #include <cstdio> #include <algorithm> #include <cstring> #include <cmath> using namespace std; typedef long long ll; ; const int INF = 0x3f3f3f3f; int…
http://codeforces.com/contest/435/problem/C…
B. Pasha Maximizes time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Pasha has a positive integer a without leading zeroes. Today he decided that the number is too small and he should make it…
链接:http://codeforces.com/contest/435/problem/A   A. Queue on Bus Stop time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output It's that time of the year when the Russians flood their countryside su…
A.水题. #include <cstdio> #include <iostream> #include <cstdlib> #include <cstring> #include <string> #include<algorithm> using namespace std; ]; int main() { int n,m; cin>>n>>m; ; i<=n; ++i) cin>>a[i…
D.E还是很难的.....C不想多说什么... A:提意:给出每一组人的个数,以及一次车载容量,求出最少需要多少次才能载走所有的人. water: http://codeforces.com/contest/435/submission/6741997 B:提意:给出一个数,最多可以交换两个数k次,并且每次只能交换相邻的数,求最大的数是多少. water: 很水的贪心,直接从后往前扫描k位,把最大的数转移到最高位就行了.只不过晚上杀了一晚的后缀数组,木了,搞了半天.. http://codefo…
C. Cardiogram time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output In this problem, your task is to use ASCII graphics to paint a cardiogram. A cardiogram is a polyline with the following corner…
C. Cardiogram time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output In this problem, your task is to use ASCII graphics to paint a cardiogram. A cardiogram is a polyline with the following corner…