E. Runaway to a Shadow 题目连接: http://www.codeforces.com/contest/681/problem/E Description Dima is living in a dormitory, as well as some cockroaches. At the moment 0 Dima saw a cockroach running on a table and decided to kill it. Dima needs exactly T…
D. Gifts by the List 题目连接: http://www.codeforces.com/contest/681/problem/D Description Sasha lives in a big happy family. At the Man's Day all the men of the family gather to celebrate it following their own traditions. There are n men in Sasha's fam…
C. Heap Operations 题目连接: http://www.codeforces.com/contest/681/problem/C Description Petya has recently learned data structure named "Binary heap". The heap he is now operating with allows the following operations: put the given number into the…
B. Economy Game 题目连接: http://www.codeforces.com/contest/681/problem/B Description Kolya is developing an economy simulator game. His most favourite part of the development process is in-game testing. Once he was entertained by the testing so much, th…
A. A Good Contest 题目连接: http://www.codeforces.com/contest/681/problem/A Description Codeforces user' handle color depends on his rating - it is red if his rating is greater or equal to 2400; it is orange if his rating is less than 2400 but greater or…
A. A Good Contest time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Codeforces user' handle color depends on his rating — it is red if his rating is greater or equal to 2400; it is orange if…
C. Heap Operations time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Petya has recently learned data structure named "Binary heap". The heap he is now operating with allows the following…
C. Heap Operations time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Petya has recently learned data structure named "Binary heap". The heap he is now operating with allows the following…
B. Economy Game time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Kolya is developing an economy simulator game. His most favourite part of the development process is in-game testing. Once he…
题目链接:http://codeforces.com/problemset/problem/357/B 题目意思:输入n个人和m场舞蹈,给出每场舞蹈(只有3个人参与)中参与的舞者的编号,你需要为这些舞者安排衣服的颜色,使得每场舞蹈中3个舞者的颜色都满足是白,红,绿的条件. 特别要注意题目中的两句话:if some dance has two or more dancers from a previous dance, then the current dance stops being spec…
题目链接:http://codeforces.com/problemset/problem/357/A 题目意思:将一堆人分成两组:beginners 和 intermediate coders .每一个人都有一个point,给出每一个point里的总人数(Ci 个人有分数 i )和 x,y,需要找出划分为两组后,每一个组的人数(假设为a,b)符合 x <= a <= y 并且 x<= b <= y 的条件,输出这a个人是小于哪个point的,这个point还应该满足另一组的b…
http://codeforces.com/contest/738/problem/D Galya is playing one-dimensional Sea Battle on a 1 × n grid. In this game a ships are placed on the grid. Each of the ships consists of bconsecutive cells. No cell can be part of two ships, however, the shi…
http://codeforces.com/contest/738/problem/C Vasya is currently at a car rental service, and he wants to reach cinema. The film he has bought a ticket for starts in t minutes. There is a straight road of length s from the service to the cinema. Let's…
http://codeforces.com/contest/738/problem/A Polycarp has interviewed Oleg and has written the interview down without punctuation marks and spaces to save time. Thus, the interview is now a string s consisting of n lowercase English letters. There is…