Codeforces celebrates 10 years! We are pleased to announce the crowdfunding-campaign. Congratulate us by the link https://codeforces.com/10years. ×

### vepifanov's blog

By vepifanov, 9 years ago, translation, ,
Good evening!

Today I am the author of problems. I'm studying in Nizhny Novgorod State University (2 year, Mechanics and Mathematics). I want to thank the staff codeforces for assistance in preparing the contest, and, personally, Artem Rakhov and Maria Belova (for translations of problems into English). Also special thanks to Alexei Shmelev (NNSU) for writing alternative solutions.

P.S. Unfortunately, this round could be in error to register a team. For teams participating in this round will be counted "out of competition", ie, rating of participants does not change. If you register a team by mistake, you can unregister and register in person.

UPD: After the contest start, it will be available PDF-versions of the statements:
UPD: The contest is over, congratulate Ivan Popelyshev, who won this round. He was the only one who has successfully solved all five problems.

UPD: Tutorials are available.

Regards,
Прослушать
На латинице

Announcement of Codeforces Beta Round #37

• +79

 9 years ago, # |   +10 Good luck to everyone.
 9 years ago, # |   0 What's the tricks in Problem B?? orz
•  9 years ago, # ^ |   0 You should stop when the boss is died. Even before applying the item.
 9 years ago, # |   0 What was pretest 3 in Problem C?
•  9 years ago, # ^ |   0 Pretest #3:104 4 4 4 4 4 4 4 4 4Possible answer:YES0000000100100011010001010110011110001001
•  9 years ago, # ^ |   0 thanks
•  9 years ago, # ^ |   0 How about pretest 4 in same problem, please?
•  9 years ago, # ^ |   0 Test #4:206 7 7 7 7 6 7 7 7 7 7 7 7 7 7 7 7 7 6 7Possible Answer:YES000000, 0000110, 0000111, 0001000, 0001001, 000001, 00010100001011, 0001100, 0001101, 0001110, 0001111, 0010000, 00100010010010, 0010011, 0010100, 0010101, 000010, 0010110
 9 years ago, # |   0 What's the pretest 3 in Problem B?
•  9 years ago, # ^ |   0 Test #3:10 100 561 355 212 639 521 1039 716 110 170 5100 7Possible answer:YES21 60 1015 917 118 219 620 5
•  9 years ago, # ^ |   0 Thank you.
 9 years ago, # |   0 sorry but when will be the practice available ? find out my mistake  5 minute later, after the contest ended. (Problem c)
•  9 years ago, # ^ |   0 It is already available, if i'm not mistaken.
 9 years ago, # |   0 how to get all pretest during contest???
 9 years ago, # |   0 So, what is the idea about problem C ??I have constructed a prefix tree like that in Huffman coding, and traversed it to get the solution, and if I can't add the new item then it is invalidso what is wrong in this solution, as I failed in case 21 in the final test!!Thanks in advance,
 9 years ago, # |   0 can anyone tell how to do the problem C ?Thanks
•  9 years ago, # ^ |   +3 Hi arpit_s1- Sort the data, but keeping information about original positions.2-Starting with an empty string s ( representing a binary number), do the following for each number:   -If s is not the empty string, increment s by one. If this implies using an additional binary digit, then just     print NO.   -Add as many zeros to s so that it has as many digits as the value for the current number.3-In this way you build a prefix-free dictionary, so now you just have to print it in the desired order.Regards.
•  9 years ago, # ^ |   0 I'd apreciate test 87 for problem B.....Thx in advance
•  9 years ago, # ^ |   0 А по-русски, кто нибудь может изложить план решения задачи С? Спасибо.
•  9 years ago, # ^ |   +5 Imagine a big binary tree which has empty string as root, and traversing left appends a "0" and to right appends a "1". So all possible 0-1 strings of same length are at same level. Each node in the tree is associated with its corresponding 0-1 string, which is just the path from root to it.Now, count the number of strings of each length we need from input. You start at "0" : len=1 and keep moving.1.) We are at level k and we need n strings of length k . If you are at node X, you can pick nodes X , X+1 , X+2 , . . . , X+n-1 ( each node has a 0-1 string associated with it, and +1 is just binary arithmetic ) .2.) After picking n strings at this level, you have to move to next level below. But, that should not have the previously chosen ones as your prefix. So, move right one more time and then go down left, such that none of its ancestors were chosen before.3.) If n=0, you can just go down left. Going down is same as X*2 ( left shift by 1 = one more 0 at end )In step 1, if X+n-1 exceeds length k, then its not possible "NO". Try on paper with the tree figure to make it clear. I have used this in contest. So here is my code for reference http://www.ideone.com/tkipH .
•  9 years ago, # ^ |   0 What a wonderful ways it is.  Thank you very much for showing it for us.
 9 years ago, # |   0 And test 8 of problem C as well...
 9 years ago, # |   0
 9 years ago, # |   0
 9 years ago, # |   0 As there is no a function to see test cases, maybe you could share the folder with these tests, so that we could have a look at them in the following way: codeforces.ru/contests/37/tests/C?
•  9 years ago, # ^ |   0 I think this is a good idea, just like the Topcoder SRM.
 9 years ago, # |   0 May you provide me with test 76 in problem B?Thanks.
 9 years ago, # |   +3 I have found that the 3rd case of problem D has Xi = 0, but the problem statement guarantees that Xi > 0.This makes some contestants' solution get wa.
•  9 years ago, # ^ |   0 My apologies ... in the problem D in one point there was a typo. Initially, the restrictions on X and Y were as follows: 0 <= Xi, Yi <= 100.
•  9 years ago, # ^ |   0 What's the third test case for problem D
 9 years ago, # |   +3 There is a mistake in problem DThe problem said 1<=Xi<=100.But in pretest 3,the Xi becomes 0 which causes me get wrong answer  on it during the competition.But it's too late now...Someone should take the responsibility of the mistake!!!
•  9 years ago, # ^ |   +3 Why late?I think your solution will be rejudged.Email private message to the contest's author.
 9 years ago, # |   0 please give the test 4 for problem B. thanx in advance.
 9 years ago, # |   0 I read accepted solutions for problem E, but I couldn't understand. How do you paint this board in 4 days?13 13WWWWWWWWWWWWWWBBBBBWBBBBBWWBWWWBWBWWWBWWBWBWBWBWBWBWWBWWWBWBWWWBWWBBBBBWBBBBBWWWWWWWWWWWWWWWBBBBBWBBBBBWWBWWWBWBWWWBWWBWBWBWBWBWBWWBWWWBWBWWWBWWBBBBBWBBBBBWWWWWWWWWWWWWW
•  9 years ago, # ^ |   +5 0000000000000011111011111001222101222100123210123210012221012221001111101111100000000000000011111011111001222101222100123210123210012221012221001111101111100000000000000First time we paint all the board into black.Second turn - all cells except cells with distance 3 into white.Third - all except 2 and 3 into black.And last - cells, except cells with 1, 2, 3 (cells with distance 0) into white.
•  9 years ago, # ^ |   0 Thanks. I understood the solution now.