Shuvo_06's blog

By Shuvo_06, history, 18 hours ago, In English

For constructive problems like Skibidus and Rizz , where you need to identify a general pattern that works for all cases, I’d like to know how you approach such problems and what your thought process is.

is it just experience from practice or something else?

  • Vote: I like it
  • -3
  • Vote: I do not like it

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

I used to think they required some sort of strong math/logic understanding or proof writing. Now I'm convinced you just have to try random shit until it works and not worry about proving it. I think all the solutions to all the constructive problems rated under 1700 that I've practiced can be found by either writing a brute force program then identifying the pattern or by guessing something and submitting it if you can't find a counter-example.

For the problem you linked, I surprised myself came up with the idea in like 10 minutes. I was just like "Oh we need the max balance value to be exactly k, so let's just make a block of size k then try to minimize the balance value after that" then I was like "okay how to minimize the balance value? just alternate 0s and 1s?" and it worked.

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

    so, it's kinda luck based? (:

  • »
    »
    2 hours ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    guessforces became expertforces

  • »
    »
    119 minutes ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    i think of same but gave wrong answer how?

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

I read the problem and my immediate reaction was we need alternating sequence. I think you just need experience.