Rating changes for last rounds are temporarily rolled back. They will be returned soon. ×

Comments
On tibinyteI'm tibinyte, AMA, 9 months ago
0

10 is a quite big number XD. From your second list I have watched HOTD and the Witcher. idk why people are hating on the new season. They both definitely deserve to be there. I tried Vikings but it felt lame, at least initially. Few more shows not mentioned before that I'd like to (not in any specific order):

  • Narcos (great overall package)

  • The wire (currently still watching it but seems nice)

  • Stranger things (my first show, will always have a special place in my heart)

  • black mirror (dystopian)

  • arcane

Tbh once you watch shows like breaking bad, bcs and got, your expectations shoot up a lot for you to enjoy most of the other shows.

Congrats!

On tibinyteI'm tibinyte, AMA, 9 months ago
0

Hey, I have the same list of favorite shows, expect I haven't watched Spartacus. Will definitely give it a shot! Can you extend your list by a bit? I guess we have similar tastes XD

On jdurieCodeforces Round #877 (Div. 2), 11 months ago
0

By cf rating I meant the rating of the problem on codeforces website.

On jdurieCodeforces Round #877 (Div. 2), 11 months ago
0

Hey, I was wondering whether clist rating is more credible or cf rating. They do differ significantly for a lot of problems. Edit: When I talk about credibility, I don't need the absolute rating to be perfect. I only care about relative rating. What I mean is if problem x is objectively harder than problem y, it should have higher rating than problem y. This way I can filter a range of problems effectively for my practice.

On jdurieCodeforces Round #877 (Div. 2), 11 months ago
+10

Wasted 40 mins with 4 wrong submissions on D because I missed the observation that the segment length had to be even ;_;

I thought about the exact same optimization during the contest but wasted too much time trying to prove its worst-case time complexity. Here is my submission 207739872 after the contest. I still haven't figured the time complexity part yet. Do you (or someone else) have any insights?

Thanks a lot.

Hi YocyCraft. I had the exact same idea as you for D1D. I have no idea why my submission 207484281 is failing testcase three. I have tried to debug it for hours and also went through your code line by line to see if there is something that I have missed. I would be grateful if you could take a look at my code and point out why it is failing.

Are there any special prerequisites needed to solve today's E?

Thanks a lot mate! I forgot to take care of the set iterator after deleting element from it.

Hi. Can someone please help me out by letting me know why my submission 202689621 for $$$E$$$ fails?

My basic idea is to maintain a single segment tree where every node is a pair of integers. First entry is their LCA and second is the minimum number of operations. While merging segments in $$$build$$$ and $$$query$$$, I have just climbed up starting from LCAs of both the segments. This process wasn't required in $$$update$$$ because we are doing point updates in which the node takes value of its ancestor which is just one level above it (its parent). So LCA of every segment containing it either changes just by one level or doesn't change at all.

Thank you.

Yes. Just figured it out. Very unlucky ;_;

My approach is similar but I'm not able to figure out why is it failing test case 2. Could you take a look at my code 202226566? I believe it is clean and shouldn't take a lot of time to understand. I have basically simulated a process. At every iteration, if the dimensions are $$$h,w$$$, I look for piece $$$h,y$$$ or $$$x,w$$$ where $$$y<=w$$$ and $$$x<=h$$$. If we find either of these pieces, cut them out from our rectangle.

Yes. I agree with that. I'm asking if you exploited this observation anywhere in your solution. The editorial solution doesn't use this observation anywhere.

Hi. I just wanted to ask if you exploited the fact anywhere in your algorithm that the blocks are of size 1 or 2 only (because the editorial's solution has not)?

That is really surprising because if all the array elements are non-zero, it is guaranteed to overflow after less than 100 iterations since $$$2^{100} »» 10^{18+9}$$$. Therefore, every such test case should be vulnerable to failure in theory if $$$n > 100$$$. Correct me if I am wrong. In practical, it is working properly even for very large arrays.

It is indeed overflowing like I expected. The value of $$$a$$$ (first element of the array in priority queue) becomes negative after a few iterations. What's blowing my mind is that my code is still giving the correct answer for every large input I generated. The output matches with that of the editorial code. I would really appreciate if someone could take a look and explain why this is happening.

Yeah. My code should WA for the given constraints, right?

My submission 200473816 for F1 has passed but I believe it should fail. I have represented every number in the form a.m + b where m = 1000000007 and b < m. Since the number can reach $$$2^{3000}$$$, it should still be insufficient to store such numbers. Can someone please look into this?

Could you (or someone else) please elaborate the logic behind your algorithm for E? I don't seem to understand it at all. Thanks!

Interesting, thanks. Wasn't really aware of it. It was a pretty straightforward dp question in that case. Will remember it for next time.

I'm wondering how 300*2*300*300 solutions were accepted for D. Thats like (10^8)/2. Aren't 10^8 solutions supposed to TLE?

I have the exact same question. If you read this explanation here which uses totient function, it is obvious why it should be non-increasing. The dp[k] array which we initially create itself is non-increasing. But if you use the dp approach mentioned in the editorial (and not prefix-sum of totient function), I don't know how people figured it out. It would be great if someone could provide more intuition into this.

Can someone give me a small testcase for which my submission would fail? I'm not able to understand where I'm going wrong.

Your solution 174107830 for the problem 1738B significantly coincides with solutions XxDantexX/174107830, import_alok_tripathi/174109848.

As you can see, we have been flagged only because he copied my template. It was with my consent. The actual code used in the solve() function is clearly different in both submissions. I request you to recheck manually and unflag both of us.

On blobughCodeforces Round #821 (Div. 2), 19 months ago
+4

Hello. For even i, in the second part of the min function, how can you assume that the unpaired index in dp[i-1] is not i-1? Because if it is i-1, you cannot pair it with i with y cost. Thanks.

Hi, Since this is my first Hackercup, I was curious as to how hard is it get a below 2000 rank in round 2. If there is any relevance at all, what CF rank/rating does it correspond to? Thanks.

I don't think the test cases are same for everyone.

On SecondThreadMeta Hacker Cup Round 1, 19 months ago
+6

Why is B2 not available for submission? Also, when will it be available?

I have.

I tried to solve D using DSU but my submission is failing. "wrong answer jury found a smaller answer than participant (test case 150)". Not sure what that means. I tried to build the spanning tree using DSU and marked an edge connecting u and v '1' if there is another existing path between u & v and both u & v are not in the set of nodes which are connected by already marked edges. I ran the iteration once from 1 to m and once from m to 1 so that I get maximum possible marked edges without breaking the connectivity of the graph.

https://codeforces.com/contest/1726/submission/171216269 Any help is highly appreciated.

Hi. I tried the same here. Did one iteration from index 1 to m and one from m to 1 but my submission is failing for some reason. Any help is appreciated. https://codeforces.com/contest/1726/submission/171216269

On RhodoksCodeforces Round #810, 21 month(s) ago
0

Don't have to sort. Just keep a flag for if you are encountering a pigment which can form a strip of width at least 3. This will help in the case you have only one strip of width 1 left uncolored on the board.

Changed float to double and it works now. Thanks though.

Hi, Can someone please explain why my SUBMISSION is failing test case 7? I tried CF Stress as well. It couldn't find any counterexample.

Thanks.

On wxhtzdyCodeforces Round #798 (Div. 2), 22 months ago
0

Hi, For tree questions like C, it is guaranteed that is there is an edge between u and v and u>v, then u is farther from the root than v? Thanks.

On huangziruiCodeforces Round #796, 23 months ago
0

Can somebody explain how Div2E is done? I looked into a couple of solutions. I understood until the part they found the length of each track and sorted the tracks. After doing so, they iterated on tracks (shortest track first) and at each iteration, greedily checked whether the track belongs to the same forest as the shortest track. They always returned the 'value' of the forest with shortest track. This looks clearly wrong because a forest containing shortest track need not have a the least 'value'. I am definitely missing something. Any help will be appreciated.

Hi @jimm89. I tried DFS too. Got TLE. Used memoization and it worked. Its kinda weird that you need memoization for this. I initially thought the probability that you will encounter a value you encountered before is so low. I thought the overhead for using a map would harm more than it will help but it is the other way around :-) I was just curious if I will need memoization for BFS as well.

WHat?