### I_Love_Tina's blog

By I_Love_Tina, history, 4 years ago,

Hi everyone!

I want to present you the Codeforces Round #361 (Div. 2) that will take place on the 6th of July at 19:35 MSK. The contest was prepared by Gabriel reality Cojocaru and Mihail ThatMathGuy Tarigradschi.

I'd like to thank Dan dans Sagunov and Gleb GlebsHP Evstropov for their help in preparing the round and for making the round possible,Mike MikeMirzayanov Mirzayanov for the great Codeforces and Polygon platforms.

Good luck in the contest!!

UPD1.In this round you will help our hero Mike solve tasks he encounters every day.

UPD2. Editorial

UPD3.Congratulations to the winners of the round.

Div 1:

1.Um_nik

2.cgy4ever

3.anta

5.ksun48

7.Kaban-5

9.skyvn97

Div 2:

1.Sky4teen

7.fenchen

8.Grandpa

10.raiders

• +284

 » 4 years ago, # |   -7 Wow ! everyone got a "middle" name :) ;)
•  » » 4 years ago, # ^ |   -16 Ahmad musa.cse12 Musa
•  » » » 4 years ago, # ^ |   -11 batpari
•  » » » » 4 years ago, # ^ |   -7 Mohammad Abdullah jackal_1586 Matin Khan Zarzis
• »
»
4 years ago, # ^ |
-23

#### set a flag that I will increase my rating 100+.Hope not to hit my face.

•  » » » 4 years ago, # ^ |   0 so... i don't know about you, but I just hit my face :c
•  » » » » 4 years ago, # ^ |   0 i hit my face last week too :<
 » 4 years ago, # |   -30 Yah i'll try to do better than past.
•  » » 4 years ago, # ^ |   0 I hope you will!Good luck!
•  » » » 4 years ago, # ^ |   -49 i also. You too.
 » 4 years ago, # | ← Rev. 2 →   +48 Wow really short announcement... I hope problem statements will be the same ;)
•  » » 4 years ago, # ^ |   -37 Yes i also think so.
 » 4 years ago, # | ← Rev. 2 →   +87 For all muslims, this time we're gonna participate with our stomachs filled.Eid Mubarak :D
•  » » 4 years ago, # ^ | ← Rev. 2 →   +12 To Cyan finally ! :V Eid Mubarak
•  » » » 4 years ago, # ^ |   0 Good luck :3
 » 4 years ago, # |   +3 we are eagerly waiting for this :)
 » 4 years ago, # | ← Rev. 3 →   +57 Eid Mubarak Everyone :)
•  » » 4 years ago, # ^ |   -18 Eid mubarak.
 » 4 years ago, # |   +16 The next day of contest will be Eid Day. Eid Mubarak everyone. Wish you'll have a nice Eid Day.
•  » » 4 years ago, # ^ |   0 you too
 » 4 years ago, # |   +25 What's better than a round at the beginning of the summer vacation :)
•  » » 4 years ago, # ^ |   +13 vacation's ending in India :(
 » 4 years ago, # |   +6 I have two questions. Where is delinur? I haven't seen that handle in announcements for a long time. And who translates problems now?
•  » » 4 years ago, # ^ |   +15 Sad but true. Delinur left Codeforces. I believe the translations are made by authors if they do not give any credits to other people. Or by someone else, by occasion.Some info from Mike, by the way.
 » 4 years ago, # | ← Rev. 2 →   -63 plz no more down votes:'(
 » 4 years ago, # | ← Rev. 2 →   -62 no down votes plz! i will never comment again:'(
 » 4 years ago, # |   -37 Will it be only in English?
 » 4 years ago, # | ← Rev. 3 →   +17 So, After a complete cycle(360 degree), this gonna be the first round in the first quadrant.Codeforces Round #(360+1) (Div. 2)
•  » » 4 years ago, # ^ |   +11 It is also 19 squared!
•  » » » 4 years ago, # ^ |   +19 So it's about the game of Go :D
 » 4 years ago, # | ← Rev. 2 →   0 For all muslims .. Eid Mubarak
 » 4 years ago, # |   +13 Hope the problems will be as real as your handle, reality, unlike something as "The family has 100,000 men give presents to each other."
 » 4 years ago, # |   +19 Oh no, ThatMathGuy! I am never forget a problem on analytic and algebraic topology of locally Euclidean metrization of infinitely differentiable Riemannian manifolds!!!!
 » 4 years ago, # | ← Rev. 2 →   +54
•  » » 4 years ago, # ^ |   -15 double check is quiet like to check: if (n == n) { //no comment ;) } 
•  » » » 4 years ago, # ^ |   +43 Surprisingly, this is not really useless check.
•  » » » » 4 years ago, # ^ |   0 But n is integer, not float :)
•  » » » » » 4 years ago, # ^ |   +3 I think Zlobober is talking about the general case because in the current case there is no n at all.
•  » » » 4 years ago, # ^ |   +15
•  » » » » 4 years ago, # ^ |   +17 Could you explain why ? Thanks. I thought there is no precision error so they should be equal.
•  » » » » » 4 years ago, # ^ |   +22 Nan equals nothing, including itself :P
•  » » » » » » 4 years ago, # ^ |   +10 Thanks, I didn't know that double type has a special value(NAN) before
•  » » » » » » 4 years ago, # ^ |   0 What about the first one? if(a[0]==a[1])
•  » » » » » » » 4 years ago, # ^ |   +1
•  » » » » » » » » 4 years ago, # ^ |   0 Ohh!!! I didn't know that. Thanks :)
•  » » » 4 years ago, # ^ | ← Rev. 2 →   -10 
•  » » » 4 years ago, # ^ |   0 NAN :)
 » 4 years ago, # |   -9 The time for this contest is too bad for us! Because it's 00:35 in China. What's worse is that I have lessons tomorrow morning,so my mother doesn't allow me to take part in this contest.I think i must take part in the contest secretly.But,if my mother find me doing this,I think my mom will clapperclaw me.How miserable i am ! Bless me not to be found，codeforces!
•  » » 4 years ago, # ^ |   -9 An addictive competitive programming is one which you cannot stop taking once you have started
 » 4 years ago, # |   -8 Hope to do better this time !!
 » 4 years ago, # |   0 Contest just before Eid. It'll be interesting! Eid Mubarak everyone.
•  » » 4 years ago, # ^ |   -14 Eid Mubarak.
 » 4 years ago, # |   -27 Ohh! a contest wrote by Moldovans , seems to be a good one !!
 » 4 years ago, # |   -25 Eid mubarak....!
 » 4 years ago, # |   -9 Those who have summer vacation, Happy summer vacation and Eid Mubarak to everyone wish you a happy, prosperous and AC life ;)
 » 4 years ago, # |   -9 Always waiting for the hell-mode problem :3_thanks for your great test
 » 4 years ago, # |   -9 Good luck Guys
 » 4 years ago, # |   +2 Hoping to see some good problems and ratings up. All the best to all.
 » 4 years ago, # |   0 Nice & Short Announcement . Hope to have the Problems will be similar to the size of announcement and interesting. All the best for all the contestants . Wish you a very high Ratings which makes the following festival much more interesting.
 » 4 years ago, # |   +21 Recently I can't open submission code of old problems(Rounds before about 100), including my own submission. Anyone has any idea about this problem? Thanks.
•  » » 4 years ago, # ^ |   +12 facing similar problem!!
•  » » 4 years ago, # ^ |   +7 yeah I have this problem too ...
 » 4 years ago, # | ← Rev. 2 →   +50 This round and every other round hero. Thanks to mike for the great Codeforces and Polygon platforms
•  » » 4 years ago, # ^ |   +7 sry for positioning of his head:)
 » 4 years ago, # |   +30 Does anybody feel that the A problem is a lot harder than usual ???
•  » » 4 years ago, # ^ |   +2 Yes!! I am not able solve it :(
•  » » 4 years ago, # ^ |   -7 Yes, It's too hard.
 » 4 years ago, # |   +20 Is it just me who thinks this round is scary difficult?
•  » » 4 years ago, # ^ |   +19 I've actually checked if it's div 1.
•  » » » 4 years ago, # ^ |   +1 I've checked too :D
•  » » » 4 years ago, # ^ |   +36 I think problems should be named like this
•  » » » » 4 years ago, # ^ |   +3 LooooooooooooooLXDXD
 » 4 years ago, # | ← Rev. 2 →   +3 My dream to become Cyan has been destroyed :(
•  » » 4 years ago, # ^ |   +1 i'm becoming Newbie again
 » 4 years ago, # |   0 I think this round is too hard. :'(
 » 4 years ago, # |   +22 This round has really made me take a reality check. ;_;
 » 4 years ago, # |   +3 How to solve B? Dijkstra?
•  » » 4 years ago, # ^ |   0 i solved with bfs
•  » » 4 years ago, # ^ |   0 Simple BFS would do. Just think how you can make graph unweighted.
•  » » » 4 years ago, # ^ |   0 Got you. Thanks )
•  » » 4 years ago, # ^ |   0 BFS
•  » » 4 years ago, # ^ |   0 ad-hoc or dp like
•  » » 4 years ago, # ^ |   +3 BFS ! AS all cost are +1 for each node bfs to a[i],i-1 and i+1
•  » » 4 years ago, # ^ |   +6 Just add edges [i — 1, i], [i, i + 1], [i, a[i]] and find shortest path from 1 to i.
•  » » 4 years ago, # ^ | ← Rev. 2 →   +13 Simple BFS should do the trick. Keep an array storing the minimum distance from 1 to each node and initialize all values to inf and dist[1] = 0. Then, from each state, you can reach the node to your left and right with time=1. As well, you can reach the state which has a shortcut to in distance[1]. Only visit a state that you have never been to before and update the dist[] array as you go. **Edit, when I wrote this, there were no replies. Guess everyone wanted to help!
•  » » » 4 years ago, # ^ |   +5 Dude can you explain with some code?
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   0
•  » » » » » 4 years ago, # ^ |   0 Dude, what is wrong in this code? My Code
•  » » 4 years ago, # ^ |   0 yeah I used Djikstra.
 » 4 years ago, # |   +8 Really nice round) Many thanks
 » 4 years ago, # |   0 How did you guys solve D? I got pretests passed with binary searching, for every index, the segment that has the same min/max, and answering min/max queries in intervals in O(1) with RMQ.
•  » » 4 years ago, # ^ |   +1 I think it can be done using 2 pointer two... But the implementation might be complex(IDK).
•  » » 4 years ago, # ^ |   0 n = 200000 and sequence is fill with same digitwhat time complexity in your solution?
•  » » 4 years ago, # ^ |   0 Can you please explain how you used binary search?
•  » » » 4 years ago, # ^ |   +3 Let's count how many intervals are "good" beginning with i:It will be some segment [l, r>, i <= l <= r <= nThe max_a(i, l) is an increasing function, and min_b(i, l) is a decreasing function, so with binary search you can find the first index l where max_a(i, l) >= min_b(i, l), and then with another binary you can find R, so that max_a(i, r) == min_b(i, r) for every i < r <= R
•  » » » 4 years ago, # ^ |   +8 max(x , R ) is increasing with decreasing x. min(x , R ) is decreasing with decreasing x. Now find lower and upper points where max(x,R)>min(x,R) and max(y,R)
 » 4 years ago, # |   0 O(N * logN * logN) gives TL on D :( . I was way more stuck on such an easy solution of B!
•  » » 4 years ago, # ^ |   0 Same here ! Got fooled into doing dijikstras ! :(
•  » » 4 years ago, # ^ |   0 i used RMQ to answer min/maq queries in O(1), that didn't TLE
•  » » 4 years ago, # ^ |   0 Yes. I thought that my solution with Segment Tree would pass. But I got TL 7 and rewrited it using sparse table.
•  » » 4 years ago, # ^ |   0 My code has also O(n * log2(n)) time complexity. But it gets AC with 1419ms time. I used segment tree with binary search for all i (1 <  = i <  = n). Here is my submission. BTW I recommend RMQ solution with O(nlog(n)) time complexity for this problem (because of the tight time limits).PS: The funny thing is that I couldn't solve it at the contest time because I thought both Mike and !Mike can tell the Maximum value. Didn't read the problem statement well. If they can tell the Maximum value what will be the solution then? Anyone have any idea?
•  » » » 4 years ago, # ^ |   0 If they both compute maximums, they will always output the same number. Just print n*(n+1)/2.
•  » » » » 4 years ago, # ^ |   0 That's not true. For this case: 3 1 2 3 4 5 6 The answer is 0
•  » » » 4 years ago, # ^ |   0 Vhai in your solution how these two line works ?? I mean what is the logic behind this ?? when (p.fs-p.sc>0) lo=mid+1; ans else hi=mid-1; how the direction of binary search is selected ?
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   0 If we go to left then maxa will increase or remain same and minb will decrease or remain same. Now there can be 3 type of cases. 1. maxa = minb 2. maxa > minb 3. maxa < minb For second case we have to go to the right side because we want maxa to be equal to minb. For third case we have to go to the left. For first case if we want the lower bound then we go to the left. For upper bound we go to the right.
 » 4 years ago, # |   0 Nice round. How to solve C? Many people solved it very fast! I hope many A fail. :P
•  » » 4 years ago, # ^ |   +4 Binary search for least value of n that satisfies no of ways greater then or equal to m. At the end you need to check if this value is actually equal to given m or not.
•  » » » 4 years ago, # ^ |   0 what Right limit did u start with ? And how did u calculate it ?
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   +4 i actually manually checked what value could give answer till 10**15. it was around 10**16.EDIT: Screw this, damn i did checked this in a loop but since i coded binary search function first and then checked for this value, i forgot to update to 10**16. So it will fail final tests most likely :(
•  » » » » » 4 years ago, # ^ |   +3 Srry for spoiling your party before sys tests :P
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   +3 I just used 8 * 1015 since M is at most 1015.
•  » » » » 4 years ago, # ^ |   +3 Long.MAX_VALUE should be a safe bet I think.
•  » » 4 years ago, # ^ | ← Rev. 2 →   0 binary search to find n
 » 4 years ago, # |   0 I think that problem A has too week pretests. I hacked 5 solution and I will fail the system test(.
•  » » 4 years ago, # ^ |   0 same thing but 2 solutions only hacked :D
•  » » 4 years ago, # ^ |   0 Was fun finding the logic in different peoples A solutions ! Remarkable !
 » 4 years ago, # |   0 What was the hacking test cases in div2 A ?
•  » » 4 years ago, # ^ |   +3 4 93943 3493 167
•  » » » 4 years ago, # ^ |   0 What would be the faulty logic in these cases?
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   0 for example, i thought only about this pairs: 1&0, 2&0, 3&0, 1&7, 3&9. My solution passed pretests and got WA69
•  » » 4 years ago, # ^ |   +11 I hacked one solution with 5 36984Even my solution fails on this but unfortunately I cannot hack mine :(
•  » » » 4 years ago, # ^ |   +9 You are really a hell_hacker if you want to hack your own solution XD
•  » » 4 years ago, # ^ |   0 I hacked a 02MAybe 40 also was missed
•  » » 4 years ago, # ^ |   0 183 got a lot of people as it used the full 3x3 square but could be moved down to 460.
•  » » 4 years ago, # ^ |   +5 4 2469
 » 4 years ago, # |   +2 hardest round ever!
 » 4 years ago, # |   +4 finished coding D less than 1 minute after the contest ended
 » 4 years ago, # |   +6 For me round was very interesting and one of the best in last time ! Thanks !
 » 4 years ago, # |   +11 Before 30 seconds the end, i submit div2E and got WA Because i print with I64D, not I64d...my input : 3 1 1 2 2 3 3 4output : DI'm really sad...
•  » » 4 years ago, # ^ |   +7 : D
 » 4 years ago, # |   0 In Div 2 A, What was wrong in this if there is a 1,2,3 and 7,9,0 in the string, then YESotherwise NO.
•  » » 4 years ago, # ^ |   +5 2 17
•  » » » 4 years ago, # ^ |   +2 The answer is "NO"
•  » » 4 years ago, # ^ | ← Rev. 2 →   0 13the answer is no.
•  » » 4 years ago, # ^ |   0 1,7 should get a NO because it has identical finger movement to 2,8 and 5,0 and 3,9
 » 4 years ago, # |   +42 very bad statement
•  » » 4 years ago, # ^ |   +1 I had to read E for 10 minutes before I understood the problem statement.
 » 4 years ago, # |   +6 This really freaks me out!
•  » » 4 years ago, # ^ |   +1 I know that feel bro
 » 4 years ago, # |   0 wrong answer on test case # 4 :):):)
•  » » 4 years ago, # ^ |   0 You probably forgot the backwards paths from point i to point i-1. I had the same mistake :)
•  » » » 4 years ago, # ^ |   0 i forgot this and costed me 3 WA but realised it later and got AC
•  » » » 4 years ago, # ^ |   0 I don't get this test, can you explain why the result at intersection 10 = 8 ??
 » 4 years ago, # |   0 solve 3 and 2 fail maintest...
•  » » 4 years ago, # ^ |   +1 I thought this would make me rank 2000+, surprisingly rank 800+ by just solving B :)
 » 4 years ago, # |   0 My Problem A fails for n=1. Careless mistake sucks!
•  » » 4 years ago, # ^ | ← Rev. 2 →   0 same with me forgot to put else before if in a condition and got A missed :(
 » 4 years ago, # | ← Rev. 2 →   -35 Shittiest contest ever !!!
•  » » 4 years ago, # ^ |   +8 Tasks were fine by me, maybe A harder than usual, that's it o.o
•  » » 4 years ago, # ^ |   -6 Actually it was one of the best I ever gave....
•  » » » 4 years ago, # ^ |   0 Problem A and B was tricky.
 » 4 years ago, # |   -18 the worst round i have ever seen
•  » » 4 years ago, # ^ |   -14 I concur
 » 4 years ago, # | ← Rev. 4 →   0 Can someone explain why I'm missing these two questions B: 18932534 edit : oops didnt read questionthen just check c edit: ok i guess my lower bound is incorrect C: 18935173
•  » » 4 years ago, # ^ | ← Rev. 2 →   +1 long long lo=m*6; You lower limit is too high. I just used 1.(edit: too late)
 » 4 years ago, # | ← Rev. 2 →   -33 That was the bad contest I have ever seen
•  » » 4 years ago, # ^ |   +24
 » 4 years ago, # |   +24 I think many people run when they saw Div2A.
•  » » 4 years ago, # ^ |   +9 Like this
 » 4 years ago, # |   0 I can't find mistake in my D. Anyone? :) http://codeforces.com/contest/689/submission/18935532
•  » » 4 years ago, # ^ | ← Rev. 2 →   0 well first and foremost it's O(n log^2 n), which TLEs on systeststhere must be a bug in your binary search, it's easy to get it sometimes wrong by +-1 or < instead of <=, etc.
 » 4 years ago, # |   +20 I think that this contest is the worst only for people who solved only A. So you should study programming better. I liked this contest because of problems C and D. So thank you, reality and ThatMathGuy, for the round.
•  » » 4 years ago, # ^ | ← Rev. 2 →   +1 Well, I think all problem was great. but some description was too hard to understand.Really thanks for problem setter.
 » 4 years ago, # |   0 A and B didn't pass, I lost an hour for them... But C and D are easy
 » 4 years ago, # | ← Rev. 2 →   +5 Why pypy/python is so slow?? http://codeforces.com/contest/689/submission/18935945
•  » » 4 years ago, # ^ |   0 I optimized my pypy submission so test cases 1-11 were each in less than 100 ms, but it still ran out of time: http://codeforces.com/contest/689/submission/18934688
 » 4 years ago, # |   +12 Sky4Teen???? A fake Account + Shitty Naming Sense!!! :/
 » 4 years ago, # |   0 What is wrong in my soltion of Div2B: My solution
•  » » 4 years ago, # ^ |   0 A subsection of your output: 15 1 2 After a shortcut you can go both right and left.
•  » » » 4 years ago, # ^ |   0 Didn't get you. Could you be a bit more elaborate? Also , I have changed my solution a bit but I am still getting a WA
•  » » » » 4 years ago, # ^ |   0 Not sure, why, but if I add if (a[start] == end) return 1; after if (start == end) return 0;, it works for testcase 6. However it is still way too slow.
•  » » 4 years ago, # ^ |   0 6 6 6 6 6 6 6 Answer 0 1 2 3 2 1 
•  » » 4 years ago, # ^ |   0 I think you don't cover the case where it's optimal to get to some node by jumping to it from a previous one and then going backwards
•  » » » 4 years ago, # ^ |   0 I have corrected it, but I am still getting a WA : Solution
 » 4 years ago, # |   +6 Made a typo in A (used brute force and forgot that there are 4 rows and not 3) and failed A on systests. :DBut I still solved B and C so I have this going for me which is nice. By "this" I mean remaining in Div.2 for eternity of course.
 » 4 years ago, # |   +8 Rating changes, come on :D
•  » » 4 years ago, # ^ |   0 Waiting for rating change !
•  » » 4 years ago, # ^ |   0 Finally!
 » 4 years ago, # |   +1 One of the best rounds I have done, was freaked out initially after seeing Div2 A though!
•  » » 4 years ago, # ^ |   0 Yeah me too :o
•  » » 4 years ago, # ^ |   0 Same feeling :D
 » 4 years ago, # |   0 But ,problems was not so cool.....!!! 4 me As Beginer....!!! (:
 » 4 years ago, # |   0 http://codeforces.com/contest/689/submission/18931907 gives WA but http://codeforces.com/contest/689/submission/18936829 gives AC I can't understand the reason for it
•  » » 4 years ago, # ^ |   0 you're missing one 0
•  » » » 4 years ago, # ^ |   0 what do you mean ?
•  » » » » 4 years ago, # ^ |   +1 I think you should have i <= 1000000
•  » » 4 years ago, # ^ |   +1 because when m=10^15, the answer is about 4.9 * 10^15.but when i=10^5, i*i*i = 10^15 < 4.9*10^15
•  » » » 4 years ago, # ^ |   0 OK got it thanks :)
 » 4 years ago, # |   +10 Good problems, thanks authors!
 » 4 years ago, # |   -13 I want to give Mike a shit! after this test =__=
 » 4 years ago, # |   0 Hardest round ever.
•  » » 4 years ago, # ^ |   -6 ¡Easiest and funniest round ever :P!
•  » » » 4 years ago, # ^ |   +19 you just solved problem-B
•  » » » » 4 years ago, # ^ |   0 I can't.
 » 4 years ago, # | ← Rev. 2 →   +8 Can anyone help me explain this 18922000 solution? And how to develop ideas like this?
•  » » 4 years ago, # ^ | ← Rev. 3 →   0 If you don't have any of digits 1,2,3, then any number you can "move up", so answer is NO. Same goes for left, down, and right. For example you can always "move down" if you don't use digits 7, 0, 9.My submission: http://codeforces.com/contest/689/submission/18922407 (for some reason it's badly formatted in CF)
•  » » » 4 years ago, # ^ |   0 Thank you so much! :)
 » 4 years ago, # |   0 I thought the contest was rated
•  » » 4 years ago, # ^ | ← Rev. 2 →   +3 [...] will be better if it isn't so :D
•  » » 4 years ago, # ^ |   +3 The contest is rated
•  » » 4 years ago, # ^ |   +3 Aaaaand rating updated :D
•  » » 4 years ago, # ^ |   0 And it was rated
 » 4 years ago, # |   +16 people saying EID mubarak are getting too much downvotes.Guys they are people like us and celebrate festivals like us .If somebody would have said happy christmas he would have recieved like 1000 upvotes. seriously didnt expect the coding community to be so immature.
•  » » 4 years ago, # ^ |   +10 No, if 10 people had already said "Happy Christmas!" and more people still leave comments saying just that, then they would definitely not get 1000 upvotes, they would be downvoted. Eid Mubarak is no different. It's just repetitive and adds nothing to the conversation.
•  » » 4 years ago, # ^ |   0 they mostly have only upvotes o_o
 » 4 years ago, # | ← Rev. 2 →   0 Nice round (although A was more difficult than expected) after being away for a while. Fast system testing and rating changes. Finally pretests weren't weak.
•  » » 4 years ago, # ^ |   +6 Pretests for A were REALLY weak. So many solutions were hacked :)I agree that it was a nice round
•  » » » 4 years ago, # ^ | ← Rev. 2 →   +8 Yes, for A I may be wrong, but not for C and D. Problem A doesn't have some non-obvious cases if you implement it straightforward.
•  » » » » 4 years ago, # ^ | ← Rev. 2 →   +11 n = 1 was a non-obvious case for A :P
•  » » » » » 4 years ago, # ^ |   0 No? It was an easy case not being different from the others.
•  » » » » » » 4 years ago, # ^ |   0 Easy test case — Yes Not different from others — No wa-submission ac-submission PS — both submissions were after the contest
•  » » » » » » » 4 years ago, # ^ |   +3 OK, I partially agree. It depends on the implementation (for example in my code there wasn't needed to be checked for that case: 18922236). But it's a good advice to always check your solution with a test with the minimum constraints and a test with the maximum constraints.
•  » » » » » » » 4 years ago, # ^ |   0 For my code it wasn't a special case
 » 4 years ago, # |   +78 Guys, let me teach you how to write 1000000000 properly. It is (int)1e9 (works with (long long)1e18 too). I was tired counting zeroes while hacking.And thanks for the round, problems were good (maybe, A was hard for A and E was easy for E).
•  » » 4 years ago, # ^ |   0 Since the font size are same, you can tear a piece of paper to make a ruler, or take screenshot and compare the length of them in software like mspaint.Task A is probably too complicated for Div2-A, but it is a nice task for Div1 player (many ways to fail it). :P
•  » » » 4 years ago, # ^ |   +5 my variant is shorter there is no way to press '0' 10 times instead of 9
 » 4 years ago, # |   -8 For problem D I submitted a O(nlog^2n) solution and got TLE. I resubmitted the exact same code and got AC with 1716 ms. Is the Codeforces grader usually this inconsistent?
•  » » 4 years ago, # ^ |   0 That should be impossible, because CF checks and says something like "You have submitted exactly the same code before."
•  » » » 4 years ago, # ^ |   +3 I added an empty line that won't affect the code.
•  » » 4 years ago, # ^ |   0 Why can't I see any submissions for problem-D in your submission history?
•  » » » 4 years ago, # ^ |   0 Maybe you forgot to click show unofficial.
 » 4 years ago, # |   0 Small Doubt:In problem A, for testcase: 4 1468 One solution can be 4790`. Please correct me if this is wrong. Thanks in advance.18957061
•  » » 4 years ago, # ^ |   +1 Yep, it's your code answering YES while answer is NO.
 » 4 years ago, # |   0 How to solve C with dfs ?
 » 4 years ago, # |   0 I think that this solution for B should work for relative small n, why it got WA on 4 ? or i am wrong ?
 » 4 years ago, # | ← Rev. 2 →   0 Hi all. I'm getting WA in test case 17 of problem B(DIV2). But on that case tester solution and my solution are giving same answer (on my pc).test case 17: 7.0e100my ans(on CF): 7000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 my ans(on pc): 70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 actual ans: 70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000I don't know why CF changing my output. Is there any problem with solution ? Any help will be appreciated. Thanks!
 » 4 years ago, # | ← Rev. 2 →   0 sorry a kid worte
 » 2 weeks ago, # |   0 Please fix the link to the editorial in the contest page, since it links to this post and not to the actual tutorial. Thanks for reading.