mahmoud13's blog

By mahmoud13, history, 2 years ago, In English

I was trying to solve this problem 1851E - Nastya and Potions, and I submitted this code 233066590. It's the same logic of the editorial, that's what I think, but it's getting TLE. Can anyone tell me what is the wrong with my code so it's getting this TLE?

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

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

Auto comment: topic has been updated by mahmoud13 (previous revision, new revision, compare).

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

Infinity DFS ((

»
2 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

corrected version

Spoiler