tourist's blog

By tourist, 21 month(s) ago, translation, In English

1786A2 - Alternating Deck (hard version)

Problem author: KAN

Explanation
Code by KAN

1786B - Cake Assembly Line

Problem author: KAN

Explanation
Code by KAN

1785A - Monsters (easy version)

Problem author: tourist

Explanation
Code by tourist

1785B - Letter Exchange

Problem author: tourist

Explanation
Code by PavelKunyavskiy

1785C - Monsters (hard version)

Problem author: tourist

Explanation
Code by tourist

1785D - Wooden Spoon

Problem author: tourist

Explanation
Code by tourist

1785E - Infinite Game

Problem author: tourist

Explanation
Code by tourist

1785F - Minimums or Medians

Problem author: tourist

Explanation
Code by tourist, O(n^2)
Code by tourist, O(n)
  • Vote: I like it
  • +81
  • Vote: I do not like it

| Write comment?
»
21 month(s) ago, # |
  Vote: I like it +11 Vote: I do not like it

Thanks for the editorial,waiting from a long time.

»
21 month(s) ago, # |
  Vote: I like it +3 Vote: I do not like it

Finally an editorial! After a long week and a half.

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

Another approach for B

If we are shifting to left it means we are moving in negative direction If we are shifting to right it means we are moving in positive direction

We can try all possible values of shifting by binary search, and compare if we want to shift in positive and negative direction and reduce the search space on each try

https://codeforces.me/contest/1786/submission/238301378

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

    Why is it obvious that the ith cake should be below the ith dispenser ??It maybe that a cake's last part is below start of some dispenser and another cake is below the same dispenser ?@AshutoshChoudhary

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

help with B please? what goes wrong here?

appreciated. 262313860

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

Did anyone notice that the binomal in the the solution of F is wrong ?