Please read the new rule regarding the restriction on the use of AI tools. ×

KomorGiaoGiao's blog

By KomorGiaoGiao, history, 6 hours ago, In English

This is a problem from Codeforces Round 975. I tried to solve it in the round time and expected to get higher rating. A solution of binary search to this problem jumped out in my mind, and I coded it quickly, but I got WA again and again. Please help me, maybe there are some mathematical wrong int my solution or some bugs in my codes, please pointed it out, thank you!!!!!

Problem_Link

My_Submission

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

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

You are doing binary search on a non monotone function

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

    Could you explain that why it is a no monotone function?