Tariqul's blog

By Tariqul, 13 years ago, In English

The problem link http://www.codeforces.com/contest/73/problem/B

Consider this sample input:

3

teama 1

teamb 20

teamc 10

3

17 29 35

teama

In the custom test I ran sohelH’s code for the above input which was Accepted in the contest. It gives 3 3 as output.

But when I ran some others( hos.lyric code) Accepted code for the above input. It gives 2 3 as output.

Can anyone clarify me why this difference shows?.

Am i misunderstanding something?
  • Vote: I like it
  • -6
  • Vote: I do not like it

13 years ago, # |
Rev. 4   Vote: I like it 0 Vote: I do not like it

You'd better provide link to problem statement and to "other solutions".

How could "teama" have "1" point in your case, by the way? (I mean that it is possible solution in question rely on correctness of testcase)

  • 13 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it
    I think it is correct input set. If not can you tell me why it is not correct input set?
    Thanks.
    • 13 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it
      It is not "incorrect", but such situation could not be achieved according to rules, described in problem statement: if player could be awarded only with 17, 29 or 35 points and each player initially have 0 points, than no one could ever have either 1, or 20, or 10 points.