Комментарии
На dolphinigleCROC Champ 2012 — Round 3 (Final), 3 недели назад
+17

Nice problem-set, thank you dolphinigle! When I come up with the solution of Problem D, I thought: “When can I write a problem like this?”

By the way, I think it would be better if you post this notification earlier, then there will be more people take part in.

На HolkinPVCodeforces Round #117 (Div. 2), 4 недели назад
+7

I’m surprising when my not-finished solution passed examples(as well as the pre-tests). That is the same question. The admin’s reply is just:

“I can only say, that rotation of the board does NOT change its type. So sequences with same boards but with different rotations are same.”

So I don’t know what is wrong: the standard solution, the statement or my understanding?

На undefCodeforces Round #115, 5 недель назад
+17

Really love problem E: Tower Defence. I think people who have played it before may figure out the solution very soon – at least true for me.

На Burunduk1VK Cup 2012 Round 3, 6 недель назад
+44

It’s one of the most thrilling match that I have played.

In the first half hour, I did really stupid things(Misunderstand the Problem A, and then make 7 wrong try), and get very inpatient. Then I found 30+ minutes pasted and my A got only 180pt, it was really desperate.

Fortunately, I came up with the solution just after reading the problem B. And for problem C, I got very sad when I found it was a very classical min-cost-max-flow problem . I have just re-installed my OS, and I haven’t copy the code-library. So it costs me about 10 minutes looking for my code in TC.

And the most thrilling part is waiting the result. My rank was 67 before start testing. When my code is running, I got very intense.

Lucky, I passed 3 problems, and advanced. :)

На NickolasApril Fools Day Contest , 7 недель назад
+5

Thank you!

Oh my god, now I know that the statement in Problem C is a programming language named Chef. I think people without knowing this language nearly can’t solve this problem.

На NickolasApril Fools Day Contest , 7 недель назад
+9

This contest is very interesting.

In Problem E, we get very angry CE message: “DO YOU EXPECT ME TO FIGURE THIS OUT?”, and it took me about half an hour to modify the “Hello world” into “INTERCAL”.

In Problem H, it’s much difficult than I think. I try to solve this by writing the code in Herbert (http://herbert.tealang.info/) then simulate it. But I can’t solve it until the end of contest.

By the way, is there the editorial to this contest?

На EndagorionCodeforces Round #109, 3 месяца назад
+35

Thank you Endagorion, nice problem set! Especially loved the Flatland Fencing (problem D in Div1).

На MikeMirzayanovMy Joy, 6 месяцев назад
+3
Congratulations!
Hello, Tanya!
На SeyauaCodeforces Beta Round #85, 9 месяцев назад
0
I love these short and challengeable problems.
На SeyauaCodeforces Beta Round #85, 9 месяцев назад
0
And the rating curve are nearly same. :)
На RipattiCodeforces Beta Round #81, 9 месяцев назад
+7
"Is it possible to survive artef damage that is written by nine-digit number?
Of course, if amount of your health points is ten-digit number.
fans about Disgaea"


What a crazy game! It makes me want to play.
By the way, I think the HP may overflow with a 32-bit int.

Good Luck All.
На Alex_KPRCodeforces Beta Round #80, 9 месяцев назад
+11
Really love this contest.
Especially the Problem C, it is very creative.
And the pictures in Problem B & D is so cool! Who is the author?

На wituaCodeforces Beta Round #77, 10 месяцев назад
+12
Aha, good explanation!
I'm waiting for such balance take place, because I always make mistakes.
(For example, in today's Problem C, I forget to use long long somewhere and got WA.)
Anyway, I should practice more and be more careful.
На dalexCodeforces Beta Round 76, 11 месяцев назад
+2

Although there is almost nothing new in algorithm, it's a good contest to test if you are carefully enough.

I think I should practice in some contests like this because I always make mistakes, such as today's Problem C, I make a really stupid mistake.

So, the contest is a little unusual, but also valuable.


[Edit]
By the way, my rating has no change after this contest: 2203 -> 2203.
It's a coincidence that my Rating of TopCoder for latest 3 contest is 2566 -> 2568 -> 2567, almost no change.

На ConnectorCodeforces Beta Round #75, 11 месяцев назад
+8
Good contest!

For problem B, I have read the statement twice and ask 2 questions then understand it.
I don't think this statement is so clear, but others is really clear.
 
For problem C, it's a little bit unusual.
But if you know some connections between graph and linear algebra then it will be really easy.

For problem E:
Is someone solved it by divide the people into groups?
1.Prepare: for each group, calc all important time and at that time who is the best.
Cost time O(BA2logA) where A is the amount of people in a group, B is the amount of groups.
2.Query: for the groups by binary search, and combine the left-most and right-most single ones.
Cost time O(Q(B+A)logA).
For A = B = sqrt(Q):
The time complexity is O(N1.5logN).
But I can't pass.


На Ripatti Codeforces Beta Round #74, 11 месяцев назад
0
Oh my god, you are right.
I add this optimization and runs in about 1sec.
Thank you very much, I had troubled with this several times.
На Ripatti Codeforces Beta Round #74, 11 месяцев назад
0
Oh, I did't really know why now.
I run his code in XCode on the MacOS, it only cost 4 sec.
But in Dev-Cpp on WinXP it cost more than 20sec.
Can anyone explain it?
It happens not once, I noticed that before this time.
All the time it happens the code use vector, map or some others in STL.


На Ripatti Codeforces Beta Round #74, 11 месяцев назад
0
Thank you, I understand now.
I think his ideal is something like Path compression, which I also used to solve this problem.
But my approach is union-find sets.

На Ripatti Codeforces Beta Round #74, 11 месяцев назад
+5
For problem C:
The brute force algorithm has O(N^3) time complexity for some data.
Some people use it and get a due TLE.
But when I hacked masha_and_beer's code using the data: RR...RRLL..LL
It returns that his code runs about 1000ms and get the correct answer.

I think his ideal is just the simulation without any optimization.
And I copy his code and run it for the data I hacked him, it runs about 23 sec in my MacBook.
But I run it code using Custom Test, it runs in 1sec.

Can anyone explain why his magic code runs so fast on the judgement and can Pass? 
Thanks.
На Ripatti Codeforces Beta Round #74, 11 месяцев назад
+4
1 5000
RRR...RRLLL...L (half of 'R', half of 'L')

I think this one makes you TLE.
Some brute force algorithm is O(N^3) on it.

На yaroЯндекс.Алгоритм 2011 - Раунд 2, 12 месяцев назад
+10
The problems is pretty good!

I remember a problem that is similar to D.(The author is Myth5)
(There is only Chinese version statement, I couldn't find a English one.)
It asked Ks * Ks instead of Ks * Ks * s.
But the data is about N = 50000, which is smaller than this one.

So I want to know if there is a solution for these problems?
На yaroЯндекс.Алгоритм 2011 - Раунд 2, 12 месяцев назад
+5
"Good afternoon, participants and spectators!"
It's mid-night there.

Good luck every one!
На frost_novaЯндекс.Алгоритм 2011 - Раунд 1, 12 месяцев назад
+11
Congratulation!

In my opinion, today's problem is a little strange.
And the statements is too long, I have to read it more than once to get the right meaning.

На RipattiCodeforces Beta Round #68, 13 месяцев назад
+8
I remember a problem similar to the problem E:
I have solved this, the solution is also construction, and the problem in the recent contest seems a sub-problem of this one.
But codeforces contest is just 2-hour, so it's difficult to finish it.
And it's not easy to imagine this stuff and run it in mind.
На RipattiCodeforces Beta Round #68, 13 месяцев назад
+44
Very interesting problem.
A funny fact:
In problem A, the example said that tourist win, and it will comes true. :)
На ashmelevCodeforces Beta Round #66, 13 месяцев назад
+9
Oh,No!
I forget to register.

Anyway, Good Luck All.
На nataliaCodeforces Beta Round #60, 14 месяцев назад
+3
The Problem Statement is nice, although I don't know Harry Potter so much.
And the problem A is real interesting!
На Alex_KPRCodeforces Beta Round #58, 15 месяцев назад
+3
Agree, It's so hard to get the meaning.
I can't understood both the problem C and E.
На Aksenov239Codeforces Beta Round #56, 15 месяцев назад
+13
For the problem E.
It's said "It is preffered to use cin "
But I used it and Timed out.
I add this one and get AC:
ios::sync_with_stdio(false);
На Aksenov239Codeforces Beta Round #56, 15 месяцев назад
0
The contest is pretty "Mathy".
But "Mathy" is not bad.
The problem set is really good. :)
На RADCodeforces Beta Round #55 (Div. 2), 15 месяцев назад
+3
Wow, good problems as always!

Could anyone tell me how to solve the problem E? Thanks.
My BFS timed out, because it is O(NMlogK).

На nevidomyCodeforces Beta Round #53, 16 месяцев назад
0
Ok, I find my wrong.
Thanks.
На nevidomyCodeforces Beta Round #53, 16 месяцев назад
0
It seems the test case 7 in problem D is not valid:  (By mistake, the "..." in the last means ellipsis,but the same as "." in data)
Test: #7, time: 10 ms., memory: 48516 KB, exit code: 0, checker exit code: 1, verdict: WRONG_ANSWER
Input
47 24
........................
........................
........................
........................
........................
........................
X.......................
........................
....X...................
..........X......
Output
23.6657545509435892
Answer
23.670250896057
Checker Log
wrong answer 1st numbers differ - expected: '23.6702509', found: '23.6657546', error = '0.0001900'
На Anton_LunyovThe January Cook-off on www.CodeChef.com, 16 месяцев назад
+11
It's amazing that the problem setter is you.
I admire your perfect performance at ProjectEuler.
Maybe there will be much more participant because this article.
I'm waiting for this contest!
На yaroCodeforces Beta Round #51, 16 месяцев назад
0
It's easier than the problem E in last Round, although I also can't pass it by mistake.
I think this one is similar to the last problem of APIO2010.
На yaroCodeforces Beta Round #51, 16 месяцев назад
0
C is really interesting.
Firstly I thought it should be coord <= 2.
But it shows WA.
After thinking more , I realized that it should be coord <= 4.

As for problem D:
The time limit is quite strict for my solution.
My solution got TLE, but when I change the language to MS C++ , I got Accepted.

На PetrCodeforces Beta Round 50 - впечатления, 16 месяцев назад
-5
I made more mistakes this round.   >_<

ProblemA : code in Python , the only passed one.

ProblemB : s += pool[i][j]; should be s += pool[j][i];

ProblemC : 1019make the int overflow to negative numbers

ProblemD : repeated using i in the loop: 
for(int i = 1 ; i <= 500 ; i++)
		for(int i = 0 ; i < tryit.length() ; i++)

ProblemE : want to reverse the array , but write these stupid one:
		for(int i = 1 ; i <= n ; i++)
                P
[i] = P[n + 1 - i];

I just learnt a little Python, but it seems I forget how to code in C++.
4 stupid mistakes make me go back to yellow during this wonderful match.

I'm waiting for Friday's contest. 
Good luck everyone! :)
На e-maxxCodeforces Beta Round #50, 16 месяцев назад
0
Ok the registration open again. :)
Thanks!
На e-maxxCodeforces Beta Round #50, 16 месяцев назад
0
Oh,NO!
When I remember this contest, I opened this website but it said it doesn't work.
Now the registration is closed.
На MikeMirzayanovCodeforces Testing Round #1, 16 месяцев назад
+2
Aha..
But I'm not "Cpp4ever".   
На MikeMirzayanovCodeforces Testing Round #1, 16 месяцев назад
+5
Ok, a short and funny contest at the beginning of the year.

I'm learning Python recently, so I try to write Python code today.
But it seems too slow to pass.

На RADCodeforces Beta Round #46 (Div. 2, Codeforces format), 17 месяцев назад
0
For example:
ababa
aba
2
c->ba
c->cc
The answer is :
ac => 
[a][baba]
[a][ba]
So, we can use dp[i][j]: the shortest common ancestor of a[1]...a[i] and b[1]...b[j].
dp["a"]["a"] = 1
dp["ababa"]["aba"] = dp["a"]["a"] + 1
If we know, "baba" & "ba" can generate by the same letter "c" , we can obtain the answer.

To get that, we also use a dp.
bool dp2[string][char]: can a string generate by the letter char.
But it cost O(N5) in time.
So we can compress it into an int.
На RADCodeforces Beta Round #46 (Div. 2, Codeforces format), 17 месяцев назад
0
My solution is dp instead of BFS.
I don't think BFS can work.

На RADCodeforces Beta Round #46 (Div. 2, Codeforces format), 17 месяцев назад
0
Ok.
I send you the code.
By the way, you can look the code of anyone here:
На RADCodeforces Beta Round #46 (Div. 2, Codeforces format), 17 месяцев назад
+2
Aha, a good contest with nice problems!
Problem C is not so easy to understand, but really interesting.The answer looks very easy,but hard to get.
Problem D confused me.I can't pass it till now. But also a good problem.
Problem E is really nice, I got a O(N4) dp after long thinking.


На RADCodeforces Beta Round #23, 22 месяца назад
0
Consider this data:
1 0
1 0
... (amount : n - 1)
0 1
0 1
... (amount : n)
It can be calculated that the probably of get a possible answer is O(1 / sqrt(N))
So the random algorithm 's expect time complexity is O(N sqrt(N))
But we have the O(N logN) algorithm.
We can make large data  , the random solution will get TLE.
На SyFyCodeforces Beta Round #24, 22 месяца назад
+4
I am waiting for an Alpha Round.
When is the next Alpha Round?

На MikeMirzayanovCodeforces Alpha Round #21 (Codeforces format), 23 месяца назад
+8
What an amazing contest!
And I want to know : why the page "room" refreshed when I reading others codes?
Is that means some success hack take place?

By the way , my hacks : id = "545" and id = "525" is waiting , until now.
I just upload a program generate a test case that N = 100000.

And I didn't take care of "The length of <hostname> is between 1 and 32, inclusive." in problem A , but I passed all final test case.
Is that all of the test cases from successful hacking add to the final test , like TopCoder?

На NALPCodeforces Beta Round #19, 23 месяца назад
0
Problem C is wonderful!
For 2 same letter Ai and Aj(i < j) , we call it a "match":
M[i].x = j - i , M[i].start = i.
It can be found that there are no more than 10N "match"s.
We sort them by x first , if equal , by start.
And just to consider each match and keep the left-bound.
If there are some i that:
for all i <= j <= i + u - 1 , M[j].x = u , M[j].start = M[j-1].start + 1
and M[j] >= left-bound
We make the left-bound to i + u - 1 + u.
The algorithm is O(10NlogN).
На trulo_17Round #13 problem C, 2 года назад
0
Problem C is just a DP problem.
It's clear that the number will change to T that T = x[i].
If not , we can make less changes.

I also want to know how to solve this problem with original constraints. :)
На MikeMirzayanovCodeforces Beta Round #6, 2 года назад
0
correction : 5 * 10^8 should be change to 3.333.. * 10^8 .
На MikeMirzayanovCodeforces Beta Round #6, 2 года назад
0
It was so crazy!
Maybe there is some way to calc the min amount.
But it seems impossible to output the opts:
To consider this data:
N = 10^5 , a = 1 , b = 1
Hi = 10^4
The answer is about 5 * 10^8 , you should output 5 * 10^8 integers!
На MikeMirzayanovCodeforces Beta Round #6, 2 года назад
0
What is the constraints in original task?