As an experiment the Educational Codeforces Round 33 will be rated for Div. 2. ×

### PrinceOfPersia's blog

By PrinceOfPersia, 3 years ago, ,

Codeforces round #305 is gonna take place soon and I'm the writer.

After my previous contest that many people think it was a hard contest, I prepared an easy contest to cheer you up!

I want to thank Haghani for testing this round, Zlobober for help me prepare this round and his great advises, Delinur for translating problem statements into Russian, mruxim and Yasser Ahmadi Phoulady (Rasta) for their advises and ideas, Swift for helping me choose legends and graphics and MikeMirzayanov for great Codeforces and Polygon platform and guys from Physics Olympiad that kept disturbing me while preparing this round.

This is my second official round and I hope you enjoy it.

The main character of this round is gonna be Mike (I didn't say MikeMirzayanov :D).

Also you'll meet Xaniar and Abol.

I wish you all Successful hacks and Accepted solutions and high ratings.

Scoring will be posted soon.

GL & HF!

UPD: Scoring is:

• Div.2: 500-1000-1750-2000-2750
• Div.1: 750-1000-1750-1750-2500

UPD2: Due to technical reasons we moved the round by 5 minutes.

UPD3: Contest has just ended. You can find the editorial here.

UPD4: System testing is done.

Congratulations to the winners, specially dreamoon that got to his goal !

Div.1 winners:

Div.2 winners:

See you in the next rounds.

•
• +622
•

 » 3 years ago, # |   +23 Was looking forward to this :D
•  » » 2 years ago, # ^ |   +4 huury up programmers! register! just 4700 person??
•  » » 2 years ago, # ^ | ← Rev. 3 →   +46 We Want ratings!!!!UPD: We Want DIV2 Ratings! also we have final exams tomorrow(today!)!UPD2: disappointed from RATINGS! it's 1:30 passed and nothing happened :|
•  » » » 2 years ago, # ^ | ← Rev. 2 →   +9 I'm also waiting for rating instead of sleep. UPD: rating changed.
•  » » » 2 years ago, # ^ |   0 Me too...
•  » » » 2 years ago, # ^ |   0 First time to rank good, ratings delayed... FML
•  » » 2 years ago, # ^ |   +20 Finally Dreamoon got first place in Div1!
•  » » 2 years ago, # ^ |   +5 No body read the end so I commented here :/
 » 3 years ago, # |   +31 The first round was awesome ;)
•  » » 2 years ago, # ^ |   +15 which round was it :D ?
•  » » » 2 years ago, # ^ |   +9
 » 3 years ago, # | ← Rev. 3 →   0 I see new person in the first place on contribution list!Your problems are great! I couldn't participate (I was in school), but next contest I won't miss. I have only one suggestion : please make final test cases stronger...
 » 3 years ago, # | ← Rev. 2 →   -40 Three consecutive easy contest then :P P.S Why minus ?! Weren't last 2 contests easy ?! Even some guys described them like div3 contests !!! He says this contest is also easy !!! So what is wrong with this comment.
•  » » 2 years ago, # ^ |   0 ur tone :D
 » 3 years ago, # |   0 I like your problems. Though most of them were hard for me, they were interesting :D
 » 3 years ago, # | ← Rev. 2 →   -8 I like your problems pretty much.Hope to see more interesting problems :)
•  » » 3 years ago, # ^ |   0 In my idea A and B should be solved by at least 1000 people(easy), But C,D and E should be harder. Not like the recent div2 contests that more than 1000 people solved A,B,C,D! :D
 » 3 years ago, # |   -21 It is interesting that the author thinks about the complexity of the tasks
 » 3 years ago, # |   +23 Does this round involve CoffeeMix? :D
 » 2 years ago, # |   -10 Why isn't the post on main page?
 » 2 years ago, # | ← Rev. 3 →   -16 looking forward to great problems like the last one :) wish u great contribution :) thanks :)
 » 2 years ago, # |   +17 he fell from the first place on the "Contibution list". "Let's prepare a new round to go first again", he says! :D
 » 2 years ago, # |   +3 It's great to see that there is always a unique sentence in your blog!The last one was thanking yourself! This time is about the guys from Physics Olympiad!
 » 2 years ago, # |   0 Your last round was Amazing :D wish this one be better ;)
 » 2 years ago, # |   +34 Div.1 ,long time no see!
 » 2 years ago, # |   0 good job (Y)
 » 2 years ago, # |   0 I think it will be a very interesting contest. Because the author of this contest PrinceOfPersia. I think there are a lot of hacks. ('_') Sorry for my poor english.
 » 2 years ago, # | ← Rev. 2 →   0 Your problems are great, they only need a little more concentration :D
•  » » 2 years ago, # ^ |   +1 In last round you came up, anyway gl
•  » » » 2 years ago, # ^ | ← Rev. 3 →   0 Opps :/ ,My bad.I was confused between PrinceOfPersia's round and this guy fcspartakm's rounds >_
 » 2 years ago, # |   +18 Wow, this round has Div.1, great!The time gap between Div.1 contests is so long, hope Div.1 contests will be more frequently.
•  » » 2 years ago, # ^ |   +2 Ehm, there were many div1 (some div1 only, even) rounds before. Don't expect an even distribution of contests.
•  » » » 2 years ago, # ^ |   +15 Just hope Div.1 contests will be more mush.
 » 2 years ago, # | ← Rev. 2 →   -74 sorry for the comment... my friend troll me.
•  » » 2 years ago, # ^ |   -59 please ...
 » 2 years ago, # |   -11 I can't stop looking at those adorable characters.
 » 2 years ago, # | ← Rev. 2 →   -24 Your last Round had one problem with weak test cases as i mentioned hereI wish this one be better
 » 2 years ago, # |   -36 "Yasser Ahmadi Phoulady" what a legend ! :D
•  » » 2 years ago, # ^ |   +12 He is our (Me and PrinceOfPersia) teacher. Show a little respect.
•  » » » 2 years ago, # ^ |   +32 is legend in your dictionary an abuse ??
•  » » » » 2 years ago, # ^ |   -29 your comment sounded like an abuse
•  » » » » » 2 years ago, # ^ |   -21 It's Persian's Magic :D
•  » » » » » » 2 years ago, # ^ |   -26 It's farsi not persian learn your countries language
•  » » » » » » » 2 years ago, # ^ |   0 You Can Check Persian In Translate.google.com And FUS :)
•  » » » » » » » » 2 years ago, # ^ |   -39 they should call farsi, farsi not persian !!!
•  » » » » » » » » » 2 years ago, # ^ |   +18 I don't understand why you keep insisting that it should be farsi not persian. Actually the name "Farsi" started to being common because the Arabs couldn't spell "P". So the word "Persian" is more likely to be the original one. : )
•  » » » » » » » » » 2 years ago, # ^ |   -11 sorry the time i sent that comment i was a child !! now i've grown up!! :D
•  » » 2 years ago, # ^ |   -18 Yasser Ahmadi Phoulady Rasta Actually. Rasta is part of his name not Nike name or something else.
•  » » » 2 years ago, # ^ | ← Rev. 2 →   -12 His first name (in passport) is Yasser, but everyone calls him Rasta (Rasta is not part of his name).
•  » » » » 2 years ago, # ^ |   -23 it would be more legendary if it was! :-"
•  » » » » » 2 years ago, # ^ |   -16 i dunno if what you said is good or bad but i assumed that it was bad and downvoted you
•  » » » » » » 2 years ago, # ^ |   -7 You Have Big Problems In Understanding "LEGEND"
•  » » » » » » » 2 years ago, # ^ |   0 yes i have big problems thus i downvoted you
•  » » » » » » » » 2 years ago, # ^ |   -7 I Dont Give A Fuck About It :)))
•  » » » » » » » » » 2 years ago, # ^ |   -15 you did that's why you placed a comment here :))
•  » » » » » » » » » 2 years ago, # ^ |   +1 i upvoted this because i think you didn't mean anything bad but i dunno about neverless
•  » » » » » » » » » 2 years ago, # ^ |   -33 You upvote or downvote is just related to your self. Don't spam please. :-"
•  » » » » » » » » » 2 years ago, # ^ |   -20 i downvoted this xDDDD
•  » » » » » » » » » 2 years ago, # ^ |   -25 :|
 » 2 years ago, # | ← Rev. 2 →   -15 I really waited this round.
•  » » 2 years ago, # ^ |   0 Why did you give me minus? Did I do something wrong?
•  » » » 2 years ago, # ^ |   -9 Can someone tell me what did I do wrong?
•  » » » » 2 years ago, # ^ | ← Rev. 2 →   0 wrong: you wait for round. correct: round waits for you.
•  » » » » » 2 years ago, # ^ |   0 Thanks!
 » 2 years ago, # |   0 your last contest's main character was Tavas and his stories with SaDDaS , ....That was so funny! :D . Now I really want to know what are these contest's stories between Mike and his friends! Thanks a lot for these contests.
 » 2 years ago, # |   -15 Cheer up, but not too easy :D
 » 2 years ago, # |   0 A contest from a 3rd highest contributed user of Codeforces and also a red coder in a year !!! Eagerly waiting to compete the round and hope I will stay in division — 1 after this round .
 » 2 years ago, # |   -13 this account Athee registered 16 min ago, trying to down codeforces ?
•  » » 2 years ago, # ^ |   0 how?
 » 2 years ago, # |   -24 I prepared an easy contest to cheer you up!Then why Div 2 C and E have more points than usual? I don't have a problem with harder problems, but your actions should follow your words.
•  » » 2 years ago, # ^ |   +52 Scoring is related to other contest problems, not other contests problems.
•  » » » 2 years ago, # ^ |   -32 does it mean that this div2C/div1A is harder than 299's div2C/div1A ??
•  » » 2 years ago, # ^ |   +1
 » 2 years ago, # |   0 contest synchronization with Persepolis football match ):
•  » » 2 years ago, # ^ |   0 Have a look here. There seem to be a lot of missing-a-match-for-a-contest stories there.
•  » » 2 years ago, # ^ |   +8 Next contest will be on Champion's League time
 » 2 years ago, # |   +13 +1
 » 2 years ago, # |   +1 Good luck all!
 » 2 years ago, # |   +1 Why delayed?
•  » » 2 years ago, # ^ |   +1 laggs
•  » » 2 years ago, # ^ |   +16 To get the participant numbers in both divisions to be nice and round!
 » 2 years ago, # |   +7 Delaying the rounds is really really annoying!
•  » » 2 years ago, # ^ |   +5 better than start coding late because of delays onsite :D
 » 2 years ago, # |   +8 There are 3 times more Div 2 registered contestants than there are Div 1
 » 2 years ago, # | ← Rev. 2 →   +1 1600 and 4800. Wow 6400 in total
 » 2 years ago, # |   +49 1600 Registrants in Div1 and 4800 in Div2. Is there any limit or is it just a lucky round?
 » 2 years ago, # |   +83 Now I know what easy means :-"
 » 2 years ago, # |   0 Can anyone tell me the approach to DIV 2 C ?
 » 2 years ago, # |   +30 Div1 — DThough I still found it very amazing that Swistakk was able to submit D 2 mins after he submitted C. Did you use same approach as my URL or some even more magical approach? :D
•  » » 2 years ago, # ^ |   +3 I added extra points so all the rows and columns have an even number, then did an Euler tour. It's more-or-less equivalent to your approach.
•  » » 2 years ago, # ^ | ← Rev. 2 →   +71 NOOOOOOOOO!!!! I didn't change MAXN when copying ;___;. I would have been 5th and my life would be complete, because finally I would be in Petr's blog ;_;.Of course time of 2 mins can be only reached by copying and I copied code from here: http://ki.staszic.waw.pl/task.php?name=ogrod This task is present on that site, because it was inspired by exactly that IMO problem. By the way, it can be clearly seen that my coding style significantly changed since time when I coded it (in February 2011 :P).UPD: It's very funny, I changed this and I got WA on 38th test. I assumed (4 years ago :P) that resulting graph will be connected. It seems that copying such old codes is risky decision :P.
•  » » » 2 years ago, # ^ |   +8 You already were on Petr's blog, right?
•  » » » » 2 years ago, # ^ |   0 But not on pictures with standings :P.
•  » » » 2 years ago, # ^ |   +14 In the middle of the contest, I saw that your solution will fail because of MAXN and I made a decision to put maxtest in the pretest in all problems in the future. I feel really stupid, this task is a kind of task that it's ridicules if maxtest is not in the pretests. Sorry !
•  » » » » 2 years ago, # ^ |   +3 Ah, yes, you're lucky that you said that before I have thought about complaining about that :D. But my solution will fail either way :P.Thing which makes me wonder is why Zlobober didn't take care of presence of maxtests in tests? He should be well aware of need of them.
 » 2 years ago, # |   -44 The comment removed because of Codeforces rules violation
•  » » 2 years ago, # ^ |   +15 Why? That was good contest, not as too easy as last two:)
•  » » » 2 years ago, # ^ |   -24 It's better than the last two contests .. but also not good.
•  » » 2 years ago, # ^ | ← Rev. 3 →   -46 The comment removed because of Codeforces rules violation
•  » » » 2 years ago, # ^ |   -6 Thank you very much :3
•  » » 2 years ago, # ^ |   +6 What did happen here?
•  » » » 2 years ago, # ^ |   0 nothing special!
•  » » » 2 years ago, # ^ |   0 *What happened here ?
 » 2 years ago, # |   0 How to do DIV2C/DIV1A?
 » 2 years ago, # |   +12 Much hard, so math... couldn't solve anything :( Who found it easy?
 » 2 years ago, # |   +2 Last minute connection problems ==> So frustrating!
 » 2 years ago, # |   +3 How can solutions of complexity O(q*n*m) work for the given constraints in div. 2 B . I tried to hack 4 solutions of this complexity and all were unsuccessful :/
•  » » 2 years ago, # ^ |   0 same here
•  » » 2 years ago, # ^ |   0 Same doubt. I tried once and it was unsuccessful, so I did not try again. But I am baffled.
•  » » » 2 years ago, # ^ |   0 I thought that maybe the programming language used was the issue.. so i tried to hack solutions of slower languages ..
•  » » 2 years ago, # ^ |   0 And all of them failed the system tests ..
 » 2 years ago, # | ← Rev. 4 →   +1 Why is there a restriction on size of input file to hack solution's. I could not hack a solution for TLE, it say's max size of input file should be 256 kb.
•  » » 2 years ago, # ^ |   +1 same issue . ultimately the user got tled :/
•  » » » 2 years ago, # ^ |   +5 Use Test Case generator in such cases. Write your code whose output will be the input which you want to give.
•  » » » » 2 years ago, # ^ |   0 This would have done it?
•  » » » » » 2 years ago, # ^ | ← Rev. 3 →   0 yes. Or better still use this: for(int i=0;i<500;i++){for(int j=0;j<499;j++){ printf("0 ");}printf("0\n");} So that you don't give any extra whitepsace in the input.
 » 2 years ago, # |   -6 E is really well known problem.
•  » » 2 years ago, # ^ |   -14 Apparently D too(not too well known though): http://www.cs.cornell.edu/~asdas/imo/imo/isoln/isoln866.html
•  » » » 2 years ago, # ^ |   -8 It is Eulerian path, it should be well known.
•  » » 2 years ago, # ^ |   -19 D also is well known
•  » » » 2 years ago, # ^ |   +8 It is, but I haven't seen problems with this idea for a while, so I would say D is OK.
•  » » 2 years ago, # ^ |   +30 yea, 15 ACs.
 » 2 years ago, # |   +4 Couldn't submit solution because of lags in the end.
•  » » 2 years ago, # ^ | ← Rev. 2 →   0 It was the same here
 » 2 years ago, # |   +15 Successful hacking attempt at 2015-05-26 21:34:55 (hack ID 155718)! 5 seconds before contest ends!Thanks Mike for delaying the contest... got 100 more than I deserved!!
•  » » 2 years ago, # ^ |   0 ... but 100 is all I get! T_T
 » 2 years ago, # |   0 The system crashed in the last minute here, Does anybody got the same problem?
 » 2 years ago, # |   0 Problem B Div 2 : O(N * M * Q) solution can pass ?
•  » » 2 years ago, # ^ |   0 O(Q * M) will pass
•  » » » 2 years ago, # ^ | ← Rev. 2 →   -8 Could you please tell how many instructions can be executed in judge PC within 1 sec?
•  » » 2 years ago, # ^ |   +1 NoThere solution O(NM+ Q(N+M)) if I'm right
•  » » 2 years ago, # ^ |   0 so i hacked this solution using this caes and failed, why ?
•  » » » 2 years ago, # ^ |   0 PrinceOfPersia can u review this case please !!
 » 2 years ago, # | ← Rev. 3 →   0 First time that I submit a problem for 26 times! ᕕ( ᐛ )ᕗ[Definitely will fail in system tests ⊙﹏⊙]
 » 2 years ago, # |   +5 It was userful today :-)
•  » » 2 years ago, # ^ |   +5 What was solution for C? I knew this and still couldn't solve it.
•  » » » 2 years ago, # ^ |   0 Just taking sum of mu[i] * num[i] when a number is added/removed. I spent the majority of time searching for mobius function in your answers on Quora because I had forgotten the name of the function :P
•  » » 2 years ago, # ^ |   +16 No, it wasn't. In this comment we are dealing with average value of that number, not worst case one.
 » 2 years ago, # |   +30 I bet at least 100 A's will fail (including mine).
•  » » 2 years ago, # ^ |   +29 Lol, out of 530 only 156 survived the systests :)
 » 2 years ago, # |   +3 I had a really hard time getting the coordinates for problem B of division 2 right. Probably becuase I initially solved looking for the maximum consecutive bears in both rows and columns. After this my brain melted because I started confusing x and y coordinates.
 » 2 years ago, # |   +3 Your contests are always full of hacks! I think dynamic scoring would be better for them!Thanks! :)
 » 2 years ago, # |   +12 Today's Special .. Div1 Registered 1600 Div2 Registered 4800 Div2/Div1=3 and Div2%div1=0
 » 2 years ago, # | ← Rev. 4 →   +3 I fed up with my Div1-C. Guys can some one point out mistake I made in my submission?UPD. Stupid mistake. Just need to change from int id = query[it]; --id; int x = a[id]; to int id = query[it]; --id; int x = id; and everything is fine. :(
 » 2 years ago, # |   0 5 sec , just 5 more second , I could have submitted D :( :( . I clicked the submit button and the contest was over. Hoping like hell that my soln be wrong else :'( :'(
•  » » 2 years ago, # ^ |   +1 it was WA anyway ! why sad ?!
 » 2 years ago, # |   +17 Less AC's for A than for C. Dynamic scoring would have been good today.
 » 2 years ago, # |   +19 difficulty: B
•  » » 2 years ago, # ^ | ← Rev. 2 →   +13 I don't agree.C was harder and if it had been full-feedback, you would see it.It had smaller number of AC codes just because of the particular cases.
 » 2 years ago, # |   +21 nice problems,quick editorial,quick system testing,i can say that his rounds are the bests!!
 » 2 years ago, # |   +148 Congratulations to dreamoon for winning his first Codeforces round!
 » 2 years ago, # |   +25 Div1 A was a very nice problemAbout 950 submitted but only 156 got AC (in Div 1)
 » 2 years ago, # |   +3 This was a nice contest. I was only able to solve DIV2 A and B though.
 » 2 years ago, # |   +34 dreamoon did it xD
 » 2 years ago, # |   0 What's the matter with div1 A ???
•  » » 2 years ago, # ^ | ← Rev. 2 →   0 Division by zero Some people wrote that division by zero means "-1" which is not always true 16 1 8 2 0 0 8 0 8hack test. answer = 3
 » 2 years ago, # |   +70 Two months have gone, and I still don't know how to find an Eulerian circuit. (I failed on problem C in round 296 and problem D in this round) :(
•  » » 2 years ago, # ^ |   +17 It is too simple :)
•  » » 2 years ago, # ^ |   +5 http://codeforces.com/contest/429/problem/ETry this problem :P. It's very similr to today's one, though I have never understood how it should be done ;_;.
•  » » » 2 years ago, # ^ |   +5 Yes, I can alway come up with solutions to this kind of problems, but can't accept them in the contest.In srm 617, I spent too much time on the hard problem, and had no time to code the medium problem. (PieOrDolphin, which is quite similar to this problem. I used an approach with higher time complexity, and can't copy its code.)In round 296, I copied the code from Internet, while the time complexity is O(nm), and I did't know. I failed the system test.In this round, I copied the code from accepted solution in round 296. But I made a mistake in dealing with odd cycles.I think I should practice more and add a correct and efficient code into my code template. :)
•  » » » » 2 years ago, # ^ |   0 "Odd cycles" in this problem :D?I understand that your problem is getting them properly coded and accepted, but either way, I think that best way to improve is to practice on similar problems :P.
 » 2 years ago, # |   0 I knew my C for div2 would fail after submitting. But I didn't have a better idea.It is actually fun to see yourself in top 100 (80th precisely) even during contest. :P
 » 2 years ago, # | ← Rev. 2 →   +5 What's up with DIV2 C ? Only 12 Correct submission.
•  » » 2 years ago, # ^ |   0 Actually 10 during contest time.
 » 2 years ago, # |   +115 I prepared an easy contest to cheer you up!
•  » » 2 years ago, # ^ |   0 But your picture is so..... ;)
 » 2 years ago, # |   +46 dreamoon's Dream come true Today :P
 » 2 years ago, # |   +5 I see to Div.2 results and think that dynamic scoring would be more interesting here. People who solved C would have more points.
 » 2 years ago, # |   +32 tooSimple get the 3rd place. Is there any wrong with winner announcement?
 » 2 years ago, # |   0 Problem C DIV 2 from 600 AC -> 9 AC defuq ??
 » 2 years ago, # |   0 Today I was wrong on reading and trying to solve problem C before problem B because I got the idea but failed to prove it.Looks like solving A and B in minimal time would have got me in top 100 instead of ~900.BTW really nice round, problem C and D was really good. But I think in problem B , Solution having execution time O(n*m*Q) should not passed because it would have been similar to A then.
•  » » 2 years ago, # ^ |   0 I tried to hack a submission like this, but unsuccessful :|What is the hack test?
 » 2 years ago, # |   +17 I felt very stupid when more than a hundred people solved Div1 D and I couldn't, but then came system tests...
•  » » 2 years ago, # ^ |   +9 I felt the same with Div 2 C. More than 600+ submissions, but then came the system tests...
 » 2 years ago, # | ← Rev. 2 →   +26 I think A should be at least 1750 points beacuse there is fewer people to solve A than C. (Div 1)
•  » » 2 years ago, # ^ |   +27 If the pretest of div1A can be stronger, I think more people can solve it...
•  » » » 2 years ago, # ^ |   0 I thought pretest 6 is very strong... I thought I can get Accepted if I passed pretest 6 However when I hack others with test (test 74) I found I get Wrong Answer too. How sad. And I Wrong Answer on Test 71 in final test. Not Failed in my Hack Test :(
 » 2 years ago, # |   -17 if that what you call an easy one to "cheer us up!", then please, DON'T cheer us up ever again :D
 » 2 years ago, # |   +16 Wasted lots of time on A, and don't have time to write solution for E. What a sad story!
•  » » 2 years ago, # ^ |   +6 It is a good way for me to give up div1A and try to solve B,C first...
•  » » » 2 years ago, # ^ |   0 I can't agree more. T_T
 » 2 years ago, # |   -6 I hate my coding skills. :( . Please downvote me and then find me and kill me. I don't want to go through this again :'( .
 » 2 years ago, # |   0 I prepared an easy contest to cheer you up! Noooo Comment :D
 » 2 years ago, # | ← Rev. 3 →   +8 problem D: http://www.spoj.com/problems/HCHAINS/.although I somehow got TLE today..
•  » » 2 years ago, # ^ | ← Rev. 2 →   +8 Your Euler circuit is O(nm), for example triangles with common vertex 1. On such test you run O(m) cycle O(n) times. It is really common bug.To get O(n + m) you need to keep pointer to first edge that was not checked yet in current vertex.
•  » » » 2 years ago, # ^ | ← Rev. 2 →   0 Cool, tnx. I just copy pasted model solution from spoj problem. That also means we had bad test data there.
 » 2 years ago, # |   +4 I think your first round was easier :)
 » 2 years ago, # |   +8 I see chotto_matte_kudasai in 4th place at div2. But he is not listed as winner.
 » 2 years ago, # |   +7 thank you for so easy div 1 contest (mostly for problem A)
 » 2 years ago, # |   +45 Now dreamoon says: Sorry qwerty787788 :D
•  » » 2 years ago, # ^ |   0 Did qwerty787788 admit that he is sorry_dreamoon
•  » » » 2 years ago, # ^ |   0 I don't think so, but the evidence is clear -> Who sorry_dreamoon really is
•  » » » » 2 years ago, # ^ |   0 Dreamoon says sorry_sorry_dreamoon
 » 2 years ago, # |   +2 Now this is shocking. I tried to hack Div2 B but could not even though solutions had O(N*M*Q) complexity. But then they failed system tests. Someone please explain this
 » 2 years ago, # |   +9 please don't prepare any more ("easy") contests
 » 2 years ago, # |   +6 It is unusually contest!
 » 2 years ago, # |   0 Problem E from div 2 is brilliant :) great round !
•  » » 2 years ago, # ^ |   0 ooooo really??
•  » » » 2 years ago, # ^ |   0 Yep, I've managed to code the right idea ( with the PINEX ) but my coding skills are lazy..
 » 2 years ago, # |   +3 11305842 Accepted. This is Impossible!
 » 2 years ago, # | ← Rev. 2 →   +5 Well, this round wasn't that hard. Yeah, Div1-A was a problem that I will hate a long time after this round because I somehow got WA after a couple of non-passing-pretests submission because of 2-3 forgotten lines (that I knew they should be there).However, problem B in Div1 was easy, I regret reading it only after 45 minutes just because I wasn't sure that I will solve it and I would have lost my time and actually I lost my time but on problem A :(
 » 2 years ago, # | ← Rev. 2 →   +5 DIV2 B, how this solution passed the system test with (Q*N*M)?? Please someone explain 11295339
•  » » 2 years ago, # ^ | ← Rev. 2 →   0 Yes
 » 2 years ago, # |   +1 I made a test case for DIV2B of n=500 m=500 q=5000 to hack this guy (You can see his DIV2B got tle'd) but i got maximum input limit exceeded . How could this be avoided
•  » » 2 years ago, # ^ |   +8 When hacking, you can submit input generator code instead of input file to avoid such problems
•  » » 2 years ago, # ^ |   0 I think you can upload the case generator instead of copy and paste.
 » 2 years ago, # |   0 Cool Problem Div1.A/Div2.C! A lot of failed attempts :-) Get TL :-(
 » 2 years ago, # |   0 I am getting TLE on div1E.Is there any better complexity? Mine si (Q + N) log(number_of_letters)
 » 2 years ago, # |   0 prince of persia why problem C is so difficult like problem E
 » 2 years ago, # |   0 How long does it take usually for ratings to be updated?
•  » » 2 years ago, # ^ |   0 in two hours after systests or faster
•  » » » 2 years ago, # ^ |   0 thanks.
 » 2 years ago, # |   0 A beautiful and cool content. all the problems are very interesting!
 » 2 years ago, # |   +2 it looks PrinceOfPersia changes ratings by his own.His contests' rating changes take toOoOo long
 » 2 years ago, # | ← Rev. 2 →   0 Why??? Why my raiting become 1700??? So close to Div.2 (
 » 2 years ago, # |   0 And what about the rating changes?
 » 2 years ago, # |   0 Never thought that DIV2 B can pass O(q*m) solution.How many instructions codeforce judging system allow to execute in 1 sec?
•  » » 2 years ago, # ^ |   0 q*m is not much at all — just 2.5 * 10^6 iterations. Even my python solution passed it (mine is actually O(q*(m + n)), which is twice more). Keep in mind that python is like 30 times slower that c++/C#/java.q*m*n would be more questionable — its 1.25 * 10^9 iterations.
•  » » 2 years ago, # ^ |   0 First I tried a O(N*M + QlogN) using two different Segment Trees, but it got wa4, I changed it for O (N*M + Q* (M + logN)) which ACCEPTED. After the contest I fixed the bug on my first attempt and sent it, got AC, but with a slower time than the one AC in contest. Limits should be greater, so no slow solution could pass
 » 2 years ago, # |   0 rating change please princeofpersia
 » 2 years ago, # |   0 how to solve Div 2 Problem D? Is it possible to solve it in O(n) or O(nlogn) is the optimal solution?
•  » » 2 years ago, # ^ |   +7 Optimal solution is O(n).
•  » » » 2 years ago, # ^ |   0 can you please tell me how to approach the solution in both these complexities
•  » » » 2 years ago, # ^ |   0 Don't you have a union find that makes it technically O(nloglogn) or O(n\alpha(n)) ?
 » 2 years ago, # |   0 My solution for Div2 problem D failed at testcase 51 , can someone tell me what is this testcase?
•  » » 2 years ago, # ^ |   0 You can see it Here : http://codeforces.com/submissions/ravi416
•  » » » 2 years ago, # ^ | ← Rev. 2 →   0 because of large input line, i am unable to see complete testcase. Can you help?
•  » » » » 2 years ago, # ^ | ← Rev. 2 →   0 utsav_deep answered your question!
•  » » 2 years ago, # ^ |   0 the test cases are trimmed.the input format is: n=100000; each array element is either 1 or 2expected output is: array of 100000 elements in which all elements are 1, except first element which is 2.your output: array of 100000 elements in which 1st 16 elements are 2, rest of the elements are 1
•  » » » 2 years ago, # ^ |   +1 Thanks a lot guys !!! got my stupid mistake.
 » 2 years ago, # |   +5 Div1 D was very nice! I like this problem very much:) Thank you!
 » 2 years ago, # |   0 All's fine, but where are the ratings for Div2?
 » 2 years ago, # |   +1 Can anyone tell me How this soln got accepted:--http://codeforces.com/contest/548/submission/11297296Its O (n*m*q) i.e. 10^9 .....How this runs in 2 sec...I tried to hack this sol using full constraints but this gives me unsuccessful hacking attempt....
•  » » 2 years ago, # ^ |   0 Same experience as yours. I have unsuccessful hack on 11285479, but someone else have successful hack on that using full constraints :(
 » 2 years ago, # |   +13 I hope that division 2 ratings will be published in this century ;-)
 » 2 years ago, # |   +3 No rating update for Div2?
•  » » 2 years ago, # ^ |   +1 Eeeerrmmmmm.... no)
•  » » 2 years ago, # ^ |   +3 princeofpersia are you sleeping? :D Please update the rating so that i can sleep -_-
•  » » » 2 years ago, # ^ |   +8 HAHAHA, update was done, but your difference equals exactly 0 :DD
•  » » » » 2 years ago, # ^ |   0 :D I am happy with that :)
 » 2 years ago, # | ← Rev. 7 →   +15 Congratulations to the real winners!Real Div.2 winners:
•  » » 2 years ago, # ^ |   0 What was the problem in the official one??
•  » » » 2 years ago, # ^ |   0 fake accounts
•  » » » » 2 years ago, # ^ |   +7 I think it's very unlikely that someone capable of winning Div2 would compete there with a fake account while there is also a Div1 contest.
 » 2 years ago, # | ← Rev. 2 →   -9 ..
 » 2 years ago, # |   0 I guess Div 2. was unrated :|-_-|:
 » 2 years ago, # |   +14 1700:D Now I can go to bed)
 » 2 years ago, # |   0 Please for the love of the gods !!! Rate us now !!!
 » 2 years ago, # |   0 عبوكوا
 » 2 years ago, # |   +7 i hope we see you really soon
 » 2 years ago, # |   +3 Div 2 forever. :')
 » 2 years ago, # |   0 First I use my code for problem C ( div. 2) and tried to solve test case #11.But my code failed. Then I tried using the author's code to solve that test case. And surprisingly it also failed. Where's the problem? Can anyone help?
 » 2 years ago, # |   +23 Sorry, the rating update delay was the result of our with MikeMirzayanov investigation. It is now updated.
•  » » 2 years ago, # ^ |   0 what investigation?
•  » » » 2 years ago, # ^ |   +17 Stay tuned and you'll see :-)
•  » » » » 2 years ago, # ^ |   -24 I hacked div2 B, making use of the fact that O(n*m*q) will fail, any reason for unsuccessful hacking attempt?
•  » » » » » 2 years ago, # ^ |   0 Complexity was O(q*(n+m)) in most solutions.
•  » » » » 2 years ago, # ^ |   0 Was it shown already? Or when will it be shown?
 » 2 years ago, # |   0 Can someone please review my solution 11310978 of problem 548A - Майк и факс. It give wrong output on codeforces but correct on my pc . :(
•  » » 2 years ago, # ^ |   0 That happens because you have a little bug in your code, more precisely in this for loop: for( int i=0; i<=s.length(); i= i+k ) you must know that you can´t reach the size-th element, it must be size()-1. Many compilers, even ideone ignore this mistake.
•  » » » 2 years ago, # ^ |   0 Thanks a lot friend. My mistake
 » 2 years ago, # |   0 IN problem B my submission shows wrong answer in test 4 which is Test: #4, time: 15 ms., memory: 0 KB, exit code: 0, checker exit code: 1, verdict: WRONG_ANSWER Input 5 5 30 0 1 1 1 0 1 1 0 1 1 0 1 1 1 1 0 0 1 1 0 0 0 0 0 0 3 2 2 2 2 2 4 3 1 4 3 2 4 1 2 4 1 4 2 1 5 2 4 1 4 1 5 1 2 4 2 4 4 4 1 2 3 1 4 5 1 2 2 3 1 1 5 1 3 4 1 1 5 4 1 5 5 4 2 2 Output 4 3 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 5 5 5 5 5 5 4 4 4 4 4 4 Answer 3 3 3 3 3 4 4 4 4 4 4 4 4 4 4 4 4 4 5 5 5 5 5 5 4 3 3 4 4 4 Checker Log wrong answer 1st numbers differ — expected: '3', found: '4'Here you can see that after the 1st query the maximum no. of 1 is 4 in 2nd row ,hence the answer should be 4 not 3....please clarify
•  » » 2 years ago, # ^ |   0 original matrix in this test case is 01110 11011 01111 00110 00000after first query (3,2), it will become01110 11011 00111 00110 00000hence, 3rd row has highest number of consecutive 1's, that is 3. so answer for first query is 3 and not 4.
 » 2 years ago, # |   0 WOOOO... How many Comment!!!! :O It's a record!!! ;)
 » 2 years ago, # |   +1 if that contest is easy, how will be the hardest one?
•  » » 2 years ago, # ^ |   +24 Actually, today I was thinking about preparing a really hard contest >:)
•  » » » 2 years ago, # ^ |   0 The example of B in Div.2 was really bad :/
•  » » » 2 years ago, # ^ | ← Rev. 2 →   0 That was not an easy contest . Thanks for the problems, got to learn something new :)
•  » » » 2 years ago, # ^ |   0 I think people forget that you are preparing these contests voluntarily and start demanding and complain rudely instead of asking nicely and being grateful that you are taking your own time to prepare them.
•  » » » » 2 years ago, # ^ |   0 I really enjoyed the editorial, I learned a lot from it.
 » 2 years ago, # |   0 When can you post editorials? Thanks in advance.
•  » » 2 years ago, # ^ |   0 Here the Editorial http://codeforces.com/blog/entry/18126
•  » » » 2 years ago, # ^ |   0 thanks a lot :)
 » 2 years ago, # |   +15 Is it normal to receive more than 200 points of rating if you've solved 0 problems? Results of sheisactually14 seems strange... Can someone explain how this can be?
•  » » 2 years ago, # ^ |   +13 Something seems off, when I put my mouse on top of the vertex representing the user's participation in the contest it say rank:177. However when we click the vertex it says rank is 631.
 » 2 years ago, # |   +75 Btw, lots of people are making fun of statement that this contest was supposed to be easy. Looking at number of accepted A's — that is in fact funny. But looking at the scoreboard from around ~1:30 we can say that it in fact was true. There were people (note plural) which got all 5 tasks accepted on pretests before 1:15. I got 4 of them in 0:41, cubelover was even faster (0:39) even though he didn't copy D as me. That is a very rare case. C, D and E were all easy or well known to more experienced coders (though I'm a sucker when it comes to strings, so E was neither easy nor well known to me). Of course getting tasks on pretests is not equivalent to getting them, but very often means getting right solution with minor bugs, if any — so it is also a good base to judge whether tasks are easy/hard.PrinceOfPersia, I think that your problems are nice, but this problemset was not properly balanced. Problem A was for the second time very hard for A (even swapping A and B wouldn't change that), but D and E should be more demanding. And talking about hardest problems I will advise to make them more complicated from coming up with solution point of view, because both of your E's were pretty standard for people well acknowledged with needed data structures, main difficulty was put on implementing them, I think. (Note that it is my opinion, I do not claim it to be only objective one :P).
 » 2 years ago, # |   -8 oh my god..
 » 2 years ago, # |   0 Div A is much harder than B, C, I swear.
 » 2 years ago, # |   0 :D