fugazi's blog

By fugazi, history, 4 years ago, In English

I was solving this Problem.

The root (supposed to be unique) is the second number in the first line.

But the checker shows different answer, and eventhough my answer is different than checker it still passes.

Or is it that checker is outputting something else ? like number of queries used or something?

My code

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

»
4 years ago, # |
  Vote: I like it +5 Vote: I do not like it
  • »
    »
    4 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    I thought the same for a while. But for test case 6, My code takes 2 queries but the participant output shows 1.

    • »
      »
      »
      4 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      If I understand correctly your program takes one query since 5 which is the root in this case is queried first.

      • »
        »
        »
        »
        4 years ago, # ^ |
          Vote: I like it 0 Vote: I do not like it

        okay. Yes, you're right. my bad.