By BledDest, history, 2 years ago, translation, ,

Hello Codeforces!

On September 05, 18:05 MSK Educational Codeforces Round 28 will start.

Series of Educational Rounds continue being held as Harbour.Space University initiative! You can read the details about the cooperation between Harbour.Space University and Codeforces in the blog post.

The round will be unrated for all users and will be held on extented ACM ICPC rules. After the end of the contest you will have one day to hack any solution you want. You will have access to copy any solution and test it locally.

You will be given 6 problems and 2 hours to solve them.

The problems were prepared by Mikhail PikMike Piklyaev, Vladimir 0n25 Petrov and me.

Good luck to all participants!

UPD. Editorial can be found here.

Congratulations to the winners:

Rank Competitor Problems Solved Penalty
1 eddy1021 6 148
2 bmerry 6 168
3 uwi 6 173
4 fzzzq2002 6 183
5 wrinx 6 192

Congratulations to the best hackers:

Rank Competitor Hack Count
1 halyavin 74:-11
2 Dmit_riy 17
3 scaurb 12
4 winter545 12:-3
5 Benq 9

169 successful hacks and 113 unsuccessful hacks were made in total!

And finally people who were the first to solve each problem:

Problem Competitor Penalty
A eddy1021 0:02
B wrinx 0:06
C Rawnd 0:10
D alei 0:11
E chitanda 0:20
F HIR180 0:06

• +113

 » 2 years ago, # |   +89 Hopefully it wont have geometry problems :)
•  » » 2 years ago, # ^ |   0 ahahahahhahah xD
•  » » 2 years ago, # ^ |   +13 Don't worry, we don't like geometry as much as you do :) I guarantee nothing for this round, of course, we might have prepared such. Still you can check amount of these in our previous rounds.
•  » » 2 years ago, # ^ |   0 Did I miss some recent incident with a geometry problem? Or do you mean that both times Education Round had a geometry problem we had a lot of hacks (30 hacks were a lot back then...) / authors solution were not precise enough?
•  » » » 2 years ago, # ^ |   +29 I believe that it's because 432 round has 2 geometry problems in div.2
•  » » » » 2 years ago, # ^ |   +2 checking whether dot product in 5D is >0 geometry
•  » » » » » 2 years ago, # ^ |   0 is there a way to solve that problem better than O(N3) ?
•  » » » » » » 2 years ago, # ^ |   0 It's actually O(n) since for any given point A there can be at most 10 points such that for each pair B, C angle between vectors AB and AC is greater then or equal to 90 degrees, so naive solution will find two points B and C for which angle between AB and AC is less than 90 among first 11 points
•  » » » » » » » 2 years ago, # ^ | ← Rev. 2 →   +5 It can be O(1) ;). We don't need to read input if n>=12
•  » » » » » » » » 2 years ago, # ^ | ← Rev. 2 →   0 no, i mean in general. Leave that n>=11 thing. Given n points can we do better than O(N3) ? Or just modify the question to: dot product >= C (some constant)
•  » » » » » » » » » 2 years ago, # ^ |   0 I don't get what you're asking about. If we consider question "dot product >= C" then it is completely different problem.
•  » » » » » » » » 2 years ago, # ^ |   -16 @swistakk Big-o notation describes worst-case complexity, so more like Ω(1) as a best case scenario.
•  » » » » » » » » » 2 years ago, # ^ |   0 I know what big O stands for and I maintain my opinion that this task can be solved in O(1).
•  » » » » » » » » » 2 years ago, # ^ |   +11 (meme is life)
•  » » » » » » » » » 2 years ago, # ^ |   0 Look, I'm not arguing for the point of arguing. It seems my knowledge of asymptotic notations is incomplete. May I ask why it's the upper bound?
•  » » » » » » » » » 2 years ago, # ^ |   +4 Consider such algorithm: int n; cin>>n; if (n >= 12) { cout<<"0"<
•  » » » » » » » » » 2 years ago, # ^ | ← Rev. 2 →   0 I misread your comment earlier. Do you mean to say something like this: https://pasteboard.co/GJ0r6xP.png
•  » » » » » » » » » 2 years ago, # ^ |   +5 I am not sure you get what O(1) is here. What is complexity of algorithm that for an input of length n does respectively: 100, 234, 12, 1243543, 1, 78945673657578458567, 5, 5, 5, 5, 5, 5, 5, ... operations (I mean, 100 operations for n=1, 234 for n=2 etc.)? It's O(1), because it runs in time at most 78945673657578458567 no matter the value of n is.Now what is complexity of algorithm that does that many operations: 1^3, 2^3, ..., 11^3, 1, 1, 1, 1, 1, 1, 1, ...? It's O(1)! There no such complexity as "O(n) for n<=15 and O(1) for n>15", it's just O(1).
•  » » » » » » » » » 2 years ago, # ^ |   0 Gimme more MemeS!
•  » » 2 years ago, # ^ |   +50 I bought an Geometry book after CF R 432
•  » » » 2 years ago, # ^ |   +3 So serious :D
•  » » » 2 years ago, # ^ |   0 Was it the AoPs one? I like that one.
 » 2 years ago, # |   -60 Is it rated ? No ofc. give me some down votes
•  » » 2 years ago, # ^ |   -7 So is it rated or not?
•  » » » 2 years ago, # ^ |   0 Why must unintelligent specimen like you plague our CodeForces community?
•  » » » » 2 years ago, # ^ |   0 Unfortunately, attention seeking exists in almost all communities. They will stop if you ignore them.
•  » » » 2 years ago, # ^ |   0 not
 » 2 years ago, # |   0 I hope that today's round gives me feeling of competing on codeforces and not on geometryforces or implementationforces!
 » 2 years ago, # |   +5 Why doesnt CF add Educational Rounds records to contest log
•  » » 2 years ago, # ^ |   0 We also have just discussed this topic. I plan to update all previous announcement blogs with this data after the results of current contest are up.
 » 2 years ago, # |   +53 Ban UWI please.
•  » » 2 years ago, # ^ |   0 why?
•  » » » 2 years ago, # ^ |   +2 Because hacking is illegal in my country!
 » 2 years ago, # |   -16 Ples senpais give me some up votess :v
 » 2 years ago, # |   +1 I m Gonna solve All six questions.......(Just Kidding)
•  » » 2 years ago, # ^ |   +9 And get Hacked by uwi
•  » » » 2 years ago, # ^ |   0 Lol
•  » » » 2 years ago, # ^ |   +16 Can't get hacked if you don't solve!
•  » » » » 2 years ago, # ^ |   0 Haha
 » 2 years ago, # |   0 I Have not solved more than 2 question in any Codeforces contest but Today i m gonna........Lol
 » 2 years ago, # |   +4 Can't wait the contest to end so I can watch people getting hacked by uwi!
 » 2 years ago, # |   +15 Don't worry guy contest is rate! UPVOTE ME PLZ!
 » 2 years ago, # |   0 How to solve the f**k problem A???
•  » » 2 years ago, # ^ |   0 Same Here..
•  » » 2 years ago, # ^ | ← Rev. 2 →   +15 Just solve more problems. It's the third time this problem appears on CF.UPD: 180C - Letter, and the other problem is in Gym.
•  » » » 2 years ago, # ^ |   0 can you send the solution?
•  » » 2 years ago, # ^ |   0 yes its really interesting but tough
•  » » 2 years ago, # ^ | ← Rev. 2 →   0 dp... i just solved it before 4min left ;ㅅ;
•  » » » 2 years ago, # ^ | ← Rev. 2 →   0 i think (test case 2)60 1 0 0 1 0ans = 0 0 0 1 -> 4...
 » 2 years ago, # |   +1 i can only solve F
 » 2 years ago, # |   +1 please uwi do not hack my solutions ... wait a minute I did not solve anything -_-
•  » » 2 years ago, # ^ |   0 its smart not to solve at all then get hacked after solving everything
•  » » 2 years ago, # ^ |   0 Lol,Even uwi can't hack your solution now....
 » 2 years ago, # |   0 Here it goes! Here it goes! Let the hacking begin uwi!
 » 2 years ago, # |   0 I've made simple dp on tree in E but fail. I assume that because of long long overflow. Is that good solution?
 » 2 years ago, # |   +85 why is problem F a problem F
•  » » 2 years ago, # ^ | ← Rev. 2 →   0 It's because there should have also been problem G, just didn't have enough time to prepare it.
 » 2 years ago, # |   0 Now coz its over somebody tell me A. I did nothing today :(
•  » » 2 years ago, # ^ |   +4 Count number of ones after index i and number of zeros before index i. Now answer could be zeros+ones.
•  » » » 2 years ago, # ^ |   0 why would that work. I could not solve anything. And still have no idea. I checked bmerry solution and he did the same. But why ;-;
•  » » » » 2 years ago, # ^ |   +4 Because zeros should be before ones. Delete all zeros before i. Delete all ones after i.
•  » » » » » 2 years ago, # ^ |   0 isn't that delete all 1s before i and all 0 after i. so at every iteration, I need to assume that its 1 and move accordingly??
•  » » » » » » 2 years ago, # ^ |   0 Yeah, i think so.
 » 2 years ago, # |   0 Do not use cin in F!!sigh.....
•  » » 2 years ago, # ^ |   0 Or use cin with ios_base::sync_with_stdio(0);
•  » » » 2 years ago, # ^ |   0 But then i cant use printf safely.You know, sometimes printf is much more convenient than cout, such as printf("%d %d %d\n", i, j, k) vs cout << i << " " << j " " k << endl;
 » 2 years ago, # |   0 Did someone solve problem D with a 2D Segment Tree?
•  » » 2 years ago, # ^ |   0 I solved it using 2D sparse tables, it used n^2logn memory, but O(1) queries :D
•  » » 2 years ago, # ^ |   +1 It can be solved easily using 2d RMQ. You can check my submission
•  » » 2 years ago, # ^ |   +4 It can also be solved with pure binary search. sort the times and binary search on the first event that makes the screen broken. in each check of the binary search, use a table of N by M and another dp one. fill it with 0's and put 1's on the places that were broken until that event. use dp to find in O(NM) the largest square completely made out of 1's. if its size is at least k, then at this moment of time the screen is already ruined, otherwise it's not.total time: O(NM * log(NM))
 » 2 years ago, # |   0 The problem F is too easy. It should be problem B.
 » 2 years ago, # |   0 It seems that the checker for the problem F is incorrect. My solution got AC, even though the absolute error is more than 0.0001 on the testcase #15.
•  » » 2 years ago, # ^ |   0 (14792.348508-14792.3)/14792.348508 = 3.27926292e-6 < 1e-4. the statements says relative or absolute error, so in this case relative error is used.
•  » » » 2 years ago, # ^ |   +5 Previously only absolute was in statement, it was changed after this comment
 » 2 years ago, # |   -12 It was nice round xD,although i was only able to Solve Problem A, and B was greedy but :/ welp(After Solving A)
 » 2 years ago, # |   +11 Today is my birthday. So please don't hack my solutions @uwi :)
 » 2 years ago, # |   -15 Is it unrated round?
 » 2 years ago, # |   -16 Is it rated round?
 » 2 years ago, # |   +5 BledDest, you seem to have forgotten to add the editorial to contest materials, please add it so people can find it more easily. Thanks!
•  » » 2 years ago, # ^ |   +8 Done.
 » 2 years ago, # |   0 Hey guys I can't figure out problem A why the answer of this input is "4"? input : 0 1 0 0 1 It seems maximum possible is 3 011 or 001 could you help me?
•  » » 2 years ago, # ^ |   0 I think I got it...