Rating changes for last rounds are temporarily rolled back. They will be returned soon. ×

onceincentury's blog

By onceincentury, history, 5 years ago, In English

hi! Recently I found during hack of 57024850,but though it's take 15 second in testcase t=1,n=1000000000,x=100000000 my hacks fails.

It doesn't take time limit in hacks?? Sorry for my poor English.

Thank You!!

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

»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it

umm try checking the constraints again its x<n and ur x and n are equal, it fails coz of that probs

»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it

I think it must be optimized by c++ itself

»
5 years ago, # |
  Vote: I like it +10 Vote: I do not like it

Run the code in custom invocation to see its running time in CF environment.

»
5 years ago, # |
Rev. 2   Vote: I like it 0 Vote: I do not like it

Try adding -O2 to your compilation flags locally, then it should be really fast.

»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Looks like it is fast enough, there are at most 10^10 operations, which should run in time.