SampersandU's blog

By SampersandU, history, 8 years ago, In English

http://codeforces.me/contest/514/submission/26169645 http://codeforces.me/contest/514/submission/26169620

How is that even possible?? The only difference between the sources is the declaration of the Set container (double). Is there anybody who can explain THAAT?????

  • Vote: I like it
  • +52
  • Vote: I do not like it

»
8 years ago, # |
  Vote: I like it +9 Vote: I do not like it

Just never use set to count doubles. Use epsilon when you work with doubles, or try to avoid doubles in program.

»
8 years ago, # |
  Vote: I like it +4 Vote: I do not like it

A similar question was asked a few weeks ago. Take a look at my comment for more information.

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

    However, I don't see why the declaration of set in the global area adds at the 8th test ~11 extra elements, returning 47 instead of 36.