Algorithmix's blog

By Algorithmix, 13 months ago, In English

In today's Div 1+2 E, I used a fenwick tree.

234313772 WA1 234313386 Accepted due to commenting that #define int ll

So why ? I had already been facing negative value for tc2 during contest and I got bored and abandoned it. But after contest I found that line was the reason.. WHY? I really can't figure out a reason.

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

»
13 months ago, # |
Rev. 3   Vote: I like it +24 Vote: I do not like it

It has something to do with memset. This 234321001 and this 234321479 workss maybe because int is 4 bytes and long long is 8 bytes