maroonrk's blog

By maroonrk, history, 3 weeks ago, In English
  • Vote: I like it
  • +154
  • Vote: I do not like it

»
3 weeks ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

Auto comment: topic has been updated by maroonrk (previous revision, new revision, compare).

»
3 weeks ago, hide # |
Rev. 7  
Vote: I like it +12 Vote: I do not like it

P3 unusually being the most easy one there. Assumes S is always 3, we can divide the 2x2 square into 4 case based on the empty square touching left, right, up, down borders and observe that the condition only hold when for each row, the 2x2 square that got its left border touched are all to the right of the ones with right border touched, and the same hold for each column with up and down border. From that we can skillfully insert the newly one of 4 type of 2x2 square so that the "blank" 2x2 square formed a connected region and each row and column got filled step by step from its left, right, up, down. Specifically, we will insert square into the leftmost, rightmost, up-most, down-most row, collumn with empty 2x2 square, the empty square of that row-col will form a continous segment and choose which end of that segment to put new squares.

»
3 weeks ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

I did make a discussion blog here, but that got hidden from review bombing. Now that there is a solution blog, at least it won't be IOI23 again

P3 being the easiest IOI task (in terms of ACs) of the last 5 years probably indicates a higher bottom line for Day2 tasks, since the last time something got close to being this easy, it was being emergency-nerfed to oblivion after a nightmarish D1

»
3 weeks ago, hide # |
 
Vote: I like it +45 Vote: I do not like it

Upsolving is also now available on codeforces.

»
3 weeks ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

When I see IOI problems every day — incredibly difficult ones — and recall that I can't solve them, I feel like I’m stagnating, even though that’s not logical at all. Thinking about the problems I try and fail to solve daily, and then opening an IOI problem, feels like the difference between kindergarten and graduate school.

»
3 weeks ago, hide # |
Rev. 3  
Vote: I like it +54 Vote: I do not like it

Full solution to ballmachine (translated by ChatGPT)

Spoiler
»
3 weeks ago, hide # |
 
Vote: I like it +24 Vote: I do not like it

Solution for 74 points on P1:

Hint 1
Solution for 47 points
Hint 2
Hint 3
Hint 4
Solution for 71.6 points
Solution for 74 points
Bonus: Solution for 75 points
»
3 weeks ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

Day 2 statements and translations are published.

»
3 weeks ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Kevin114514 Congrats on first place

»
3 weeks ago, hide # |
 
Vote: I like it +270 Vote: I do not like it

Nice problems!

»
3 weeks ago, hide # |
 
Vote: I like it +18 Vote: I do not like it

For the problem "Ball Machine" (Day 1), I'd like to discuss how small the score $$$C := K + B$$$ can be. We already have a solution with $$$C \leq 38$$$ (in the comment of hirayuu_cf), or the order of $$$C = O(\sqrt{m})$$$, but there may be a better algorithm. (For example, I tried to prove the impossibility of logarithmic bound, but I failed. So I even think that $$$C = O(\log M)$$$ may not be impossible.)

My guess is that with $$$B = 0$$$ (that is, all balls have number zero, meaning that true/false in the function insert gives information), there might be a better solution than what we have already figured out. I'd like to know: is $$$o(M)$$$ queries, or even $$$O(\log M)$$$ queries, possible?

  • »
    »
    3 weeks ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    I don't think it's possible to do much better than O(sqrt m). Consider a tree with a bunch of branches, each has length of 2. Now it's super hard to distingush them. So doing better than O(sqrt m) might require a completely different class of solution.

    Personally, when I tried to solve this problem, all of my solutions failed due to the case when the branch is 1 (a star tree). But then I realized it's different because if the branch is 1, we just don't care about it (it's not the case when the branch is 2). So I exploited the long branches and luckily got AC

»
3 weeks ago, hide # |
 
Vote: I like it +9 Vote: I do not like it

My solution for D1 problems : https://codeforces.me/blog/entry/155972

»
3 weeks ago, hide # |
 
Vote: I like it +30 Vote: I do not like it

Day 2 is also available on QOJ.

I would also like to hear any comments of tasks, either privately or publicly, please :)

  • »
    »
    3 weeks ago, hide # ^ |
     
    Vote: I like it +10 Vote: I do not like it

    Is it possible to submit a zip file containing output files for problem "Magic City"? Thanks for uploading the tasks so soon after the competition!

»
3 weeks ago, hide # |
 
Vote: I like it +9 Vote: I do not like it

Solution to D2P2 Magic City

51.15 points
96.76 points
100 points
  • »
    »
    2 weeks ago, hide # ^ |
    Rev. 2  
    Vote: I like it 0 Vote: I do not like it

    By the way, we can prove that your 100-points answer is optimal. Congratulations!

    The minimum possible number of vertices are $$$2, 12, 24, 40, 50$$$ for $$$K = 1, 2, 3, 4, 5$$$, and $$$12K$$$ for all $$$K \geq 6$$$. For now we leave the proof to the readers, I think that it's not that difficult compared to getting 100 points :)

»
2 weeks ago, hide # |
 
Vote: I like it +95 Vote: I do not like it

We're really honored to author 2 problems this year (with E869120): Monuments (Day 1) and Magic City (Day 2). I hope you enjoyed the problems!

  • »
    »
    2 weeks ago, hide # ^ |
    Rev. 2  
    Vote: I like it +14 Vote: I do not like it

    Thank you for providing these problems, they're really cool and I enjoyed thinking about them a lot.

    If you don't mind, I would like to ask something about the monuments problem day 1. I managed to get the 71 points solution, but I got stuck there.

    After I looked up some solutions it seemed like there is a trick behind it, including some priority queue and a slope trick. Is that the intended full solution or is there another solution for it? Asking just so I know when to stop thinking about it. Thank you again for the problem.

    UPDATE: I managed to come up with some observations and took a different route, at the end I managed to get a full score on it. Absolutely stunning problem.

    • »
      »
      »
      2 weeks ago, hide # ^ |
       
      Vote: I like it +9 Vote: I do not like it

      Monuments is a problem that involves DP, but a most basic solution takes $$$O(N^3)$$$ time, so we make use of the optimal solution structure to reduce the problem to a one-dimensional DP. This will reduce to solving the following data structure problem:

      The Data Structure Problem
      Solution

      I heard that "slope trick" solution is based on the idea which interprets the problem with Minimum Cost Flow. I honestly didn't expect this solution and thought that this is a solution of a parallel world. However, it seems like some manages to solve in this way.

      • »
        »
        »
        »
        2 weeks ago, hide # ^ |
        Rev. 3  
        Vote: I like it +8 Vote: I do not like it

        Thank you for your response, I managed to come up with the observations you just well explained. And knowing that the solution I had with is the intended solution just makes me happier!

        Thank you for your efforts!

        Here is the link of my code for anyone interested

»
2 weeks ago, hide # |
 
Vote: I like it +73 Vote: I do not like it

myst-6 and I were the authors of Classroom Game (day 2)! We hope you enjoyed the problem.

»
2 weeks ago, hide # |
 
Vote: I like it +56 Vote: I do not like it

I am honoured that my problem Ball Machine was selected for the set this year, it's nice to be back on the other side after being a contestant in 2024. I hope the problem was interesting!

»
32 hours ago, hide # |
 
Vote: I like it +4 Vote: I do not like it

I don't think I've seen a solution to Classroom in this thread, so here's mine.

It actually solves a slightly harder version of the problem:
Solution
  • »
    »
    17 hours ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Legend!