vovuh's blog

By vovuh, history, 13 months ago, translation, In English

1674A - Number Transformation

Idea: BledDest

Tutorial
Solution (BledDest)

1674B - Dictionary

Idea: BledDest

Tutorial
Solution (BledDest)

1674C - Infinite Replacement

Idea: BledDest

Tutorial
Solution (awoo)

1674D - A-B-C Sort

Idea: BledDest

Tutorial
Solution (adedalic)

1674E - Breaking the Wall

Idea: BledDest

Tutorial
Solution (fcspartakm)

1674F - Desktop Rearrangement

Idea: vovuh

Tutorial
Solution (vovuh)

1674G - Remove Directed Edges

Idea: BledDest

Tutorial
Solution (awoo)
  • Vote: I like it
  • +85
  • Vote: I do not like it

| Write comment?
»
13 months ago, # |
  Vote: I like it +6 Vote: I do not like it

Thank you codeforces for this Round, Good to see many Div-3, and the standard of questions was perfect for the level of div-3

»
13 months ago, # |
Rev. 3   Vote: I like it -7 Vote: I do not like it

I think problem F will be done with Fenwick tree,too.

»
13 months ago, # |
Rev. 2   Vote: I like it +3 Vote: I do not like it

For problem E: is there some binary search solution?

»
13 months ago, # |
  Vote: I like it -10 Vote: I do not like it

It's interesting how none of the first three problems required loop.

»
13 months ago, # |
  Vote: I like it 0 Vote: I do not like it

Can anyone tell why I'm getting runtime error: Exit code is 2147483647 for submission: 155822852 I tried a lot but not understanding what's wrong.

  • »
    »
    13 months ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Failing testcase: Ticket 6533

    • »
      »
      »
      13 months ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Thanks, but why does it not run as required?
      There something wrong at line 100 tree[node1].push_back(node2);. But I'm not able to understand why this is happening.

»
13 months ago, # |
Rev. 5   Vote: I like it 0 Vote: I do not like it

After the contest, I successfully hacked most people with this example

3
3 3453 5
»
13 months ago, # |
  Vote: I like it +3 Vote: I do not like it

If you prefer command line, checkout CF Doctor for more flexibility and faster feedback.

If you are/were getting a WA/RE verdict on problems from this contest, you can get the smallest possible counter example for your submission on cfstress.com. To do that, click on the relevant problem's link below, add your submission ID, and edit the table (or edit compressed parameters) to increase/decrease the constraints.

If you are not able to find a counter example even after changing the parameters, reply to this thread (only till the next 7 days), with links to your submission and ticket(s).

»
13 months ago, # |
  Vote: I like it 0 Vote: I do not like it

Anyone overcame testcase 32 of Problem E after getting WA? Or, any equivalent short length testcase please?

»
12 months ago, # |
  Vote: I like it 0 Vote: I do not like it

can i any one tell what is wrong in my code for question infinite replacement void solved(){ string s; cin>>s; string t; cin>>t; bool infinite=false; if(t=="a") { cout<<"1\n"; return;} for(int i=0;i<t.size();i++){ if(t[i]=='a') { infinite=true; break; } } if(infinite){ cout<<"-1\n";

} else{ int ans = 1; for(int i=1;i<=s.size();i++){ ans = (ans*2)%Mod; if(ans<0) ans = ans+Mod; } cout<<ans<<"\n"; }

} int main(){ int t; cin>>t; while(t--){ solved(); } return 0; }

  • »
    »
    12 months ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    You are taking mod, thats why its giving WA for the cases where answer is >= Mod. The problem does not ask to take mod.

»
9 months ago, # |
  Vote: I like it 0 Vote: I do not like it

I know I'm quite late, but I don't see my solution to G.There is maybe a simpler (not sure if its simpler) solution to G. 1. Remove all edges u,v such that (inDegree[u]==1 || outDegree[v]==1). 2. Now the answer is the longest possible path in this new graph. Proof is also quite simple. Here is my 171163896

  • »
    »
    9 months ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Amazing solution! Easy to understand and prove!

»
4 months ago, # |
  Vote: I like it 0 Vote: I do not like it

Question F so simple... why rated 1800? It suits problem B or even A div2.